- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Problem with request script in swask OR swinstall
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-18-2002 03:06 AM
12-18-2002 03:06 AM
To start with, I have a simple request script, which reads a variabe from user. Just to add, my depot is in defaulr dir i.e, /var/spool/sw.
I am getting the following error.
# rw-rw-rw- 106/20 339 Nov 27 19:15 2002 icons/world2.png
bash: rw-rw-rw-: command not found
# swask -s /var/spool/sw \*
======= 12/18/02 14:38:24 MST BEGIN swask SESSION (non-interactive)
* Session started for user "root@lothar".
* Beginning Selection
* Target connection succeeded for "lothar:/".
* Source connection succeeded for "lothar:/var/spool/sw".
* Software bin has a "request" script. It will be executed and
corresponding "response" file will be generated.
Inside request script ... ... ...
Please enter the name
test
* Ask task succeeded.
ERROR: File "/var/tmp/BAAa24520/catalog/IFS/bin/response": No such
file or directory (2). Cannot copy it to file
"/var/spool/sw/catalog/IFS/bin/response".
======= 12/18/02 14:38:27 MST END swask SESSION (non-interactive)
Please help!
With best regards,
Nagendar
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-18-2002 04:23 AM
12-18-2002 04:23 AM
Re: Problem with request script in swask OR swinstall
#swask -s
-x ask=as_needed \*
as the command can create a response file for you.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-18-2002 04:33 AM
12-18-2002 04:33 AM
Re: Problem with request script in swask OR swinstall
The default ask option for swask is true. So, the suggested change will not have any effect. Though I tried it, same error is encountered.
Any other suggetions? Something silly happening I guess.
Any help is highly appreciated, as I am really clueless.
Thanks,
Nagendar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-18-2002 10:08 PM
12-18-2002 10:08 PM
Re: Problem with request script in swask OR swinstall
Do anyone have any idea what could be wrong, the way I am using swask? Expecting suggetions.
Thanks,
Nagendar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-18-2002 11:45 PM
12-18-2002 11:45 PM
Re: Problem with request script in swask OR swinstall
Try adding the logdetail=true and loglevel=2 options to the command. Maybe this will provide more info on why it's not working.
Regards,
Vincent
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 12:07 AM
12-19-2002 12:07 AM
Solutionswask probably doesn't succeed because the response file wasn't created. Could you please post the request file.
Here is an example of a simple request script that just asks your name and creates the response file:
echo "Please enter your name:"
read name
echo $name > ${SW_CONTROL_DIRECTORY}response
Regards,
Mateja
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 12:20 AM
12-19-2002 12:20 AM
Re: Problem with request script in swask OR swinstall
Here is a link to the Software Distributor's Administartion Guide. I think this might help you with the control scripts:
http://docs.hp.com/hpux/onlinedocs/B2355-90754/B2355-90754.html
Have a look at chapter "Using Control Scripts"
Regards,
Mateja
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 01:14 AM
12-19-2002 01:14 AM
Re: Problem with request script in swask OR swinstall
Thanks a lot. It really solved my problem.
Actually, I was thinking that response file gets generated by SW. But, I realized we need to write to it explicitly. That solves the problem!
Just a additional query I have:
When I run the same script through swinstall by ask option,
I get this error:
Please enter the name
test
* Ask task succeeded.
* Source: /var/spool/sw
* Targets: lothar:/home/isswork/nags
* Software selections:
IFS.bin
IFS.library
* Selection succeeded.
* Beginning Analysis
* Session selections have been saved in the file
"/var/adm/sw/sessions/swinstall.last".
ERROR: Could not access remote file "GLOBAL_INDEX" in software item
"". The file could not be found on the remote system.
ERROR: There is currently no installed software on host "lothar" at
location "/home/isswork/nags". (Note that you need to use
"swcopy" to manage depot software).
* Analysis had errors.
-----------------------------------------------
Any idea? But, it's not hard and fast. I can manage through swask too. But, just to know whats wrong.
Thnaks,
Nagendar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 01:24 AM
12-19-2002 01:24 AM
Re: Problem with request script in swask OR swinstall
I am glad your problem is solved.
As for the "GLOBAL_INDEX" error. You get it because you are installing to an alternate root. swinstall is looking for the INDEX file in /home/isswork/nags/var/adm/sw/products/INDEX. But INDEX there doesn't exist. You could run the same command without "-x ask=true" first to install the product (this will create an INDEX file at the above mentioned location) and then rerun swinstall:
swinstall -x reinstall=true -x ask=true IFS @ /home/isswork/nags
I hope this helps. Regards,
Mateja
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 02:24 AM
12-19-2002 02:24 AM
Re: Problem with request script in swask OR swinstall
This is weird, because I have no problem reinstalling the product. swinstall asks for response. Have you included "-x ask=true" in the command line?
btw, I am using the sample request script I posted earlier.
Mateja
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 02:42 AM
12-19-2002 02:42 AM
Re: Problem with request script in swask OR swinstall
The reason you gave seems to be correct. But, when I reinstall it, the swinstall does not wait for the user response. It just carries on ...
Any pointers?
Thanks,
Nagendar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 04:12 AM
12-19-2002 04:12 AM
Re: Problem with request script in swask OR swinstall
I am sorry!
That was not the case. Some mistake from my side. Sorru for the confusion again.
Now, the last doubt from the finishing.
As I said, I am chaninging the target while SWINSTALL. Everything is fine. Except that it shows a warning in the postinstall.
Here is the log in /home/isswork/nags/var/adm/sw/swagent.log :
* Installing fileset "IFS.library,r=" (2 of 2).
* Running install clean command /usr/lbin/sw/install_clean.
WARNING: Transition links are not created for the filesets installed
at the target. After booting up from the system using
the alternate root at the target, run tlinstall command to
create transition links.
WARNING: The command "/usr/lbin/sw/install_clean" had warnings. The
installation will continue. Check the above output for
details about the warnings.
* Building the software file
"/home/isswork/nags/var/adm/sw/needs_config" to be used for
post-reboot "swconfig" execution. The information in this
file will be used as input to "swconfig" after the system
reboots.
----------------------------------------------
Also, here is my postinstall script. It's pretty simple:
#!/bin/sh
echo "Inside postinstall script!!!!!"
echo "Root dir is: $SW_ROOT_DIRECTORY"
cd $SW_ROOT_DIRECTORY/ifs/bin
ls>output
pwd>>output
echo "======">>output
env>>output
ifsctl_file=$SW_ROOT_DIRECTORY/ifs/bin/ifsctl
IFS_DIR=$SW_ROOT_DIRECTORY/ifs
echo $ifsctl_file
sed -e "s,@IFS@,$IFS_DIR,g" < $ifsctl_file > /tmp/ifsctl_file_mod
cat /tmp/ifsctl_file_mod > $ifsctl_file
rm /tmp/ifsctl_file_mod
exit
----------------------------------------------
I should be happy after getting this answere.
With best regards,
Nagendar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 05:55 AM
12-19-2002 05:55 AM
Re: Problem with request script in swask OR swinstall
The problem is not the postinstall script. If you check /usr/lbin/sw/install_clean script you will see:
if [[ "$SW_ROOT_DIRECTORY" != "/" ]]
then
# exit if the alternate root path is neither /export/shared_roots
# nor /export/private_roots.
test_alt=${SW_ROOT_DIRECTORY#$SHARED_ROOT}
if [[ ${test_alt} = ${SW_ROOT_DIRECTORY} ]]
then
# SW_ROOT_DIRECTORY is not a NFSD shared root
test_alt=${SW_ROOT_DIRECTORY#$PRIVATE_ROOT}
if [[ ${test_alt} = ${SW_ROOT_DIRECTORY} ]]
then
# SW_ROOT_DIRECTORY is not a NFSD private root
echo "WARNING: Transition links are not created for the filesets installed"
echo " at the target. After booting up from the system using"
echo " the alternate root at the target, run tlinstall command to"
echo " create transition links."
exit $WARNING
fi
fi
fi
In your case the alternate root is /home/isswork/nags and therefore, you get the warning messages.
I hope this helps. Regards,
Mateja
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2002 06:57 AM
12-19-2002 06:57 AM
Re: Problem with request script in swask OR swinstall
I don't know how important is this tlinstall. But, is there a way to avoid this warning? Or running tlinstall for the new target? Or any other suggetion?
Waiting for the reply.
regards,
Nagendar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-20-2002 12:09 AM
12-20-2002 12:09 AM
Re: Problem with request script in swask OR swinstall
You can ignore this warning. It is just saying that transition links cannot be created because the symbolic links already exist. But if the symbolic links for the particular files already exist there is no need for creating the transition links. These kind of warning messages are common when installing to alternate roots.
regards,
Mateja