HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: swinstall script problem
Operating System - HP-UX
1833476
Members
3015
Online
110052
Solutions
Forums
Categories
Company
Local Language
back
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
back
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
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- 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
06-22-2005 08:28 PM
06-22-2005 08:28 PM
Hello,
I want to install sw or patches non interactive from a depotserver per script.
But it dont't work can anybody help me ??
I get the Message: The interactive UI was invoked, since no software was specified.
#!/bin/ksh -xv
set depotpath = ( \
10.xxx.x.xxx:/var/spool/sw/hpux11_800/SSH \*)
#
set selist = ( 05712 )
foreach sevar ( ${selist} )
echo hp${sevar}
ping hp${sevar} 200 -n 2 > /dev/null
if ($status != 0) then
echo ABBRUCH hp${sevar}
else
foreach depotvar ( ${depotpath} )
remsh hp${sevar} /usr/sbin/swinstall \
-x autoreboot=false \
-x mount_all_filesystems=false \
-s ${depotvar}
end
endif
end
-----------------------
If I try on a Client, it works fine:
swinstall -s 10.xxx.x.xxx:/var/spool/sw/hpux11_800/SSH \*
I want to install sw or patches non interactive from a depotserver per script.
But it dont't work can anybody help me ??
I get the Message: The interactive UI was invoked, since no software was specified.
#!/bin/ksh -xv
set depotpath = ( \
10.xxx.x.xxx:/var/spool/sw/hpux11_800/SSH \*)
#
set selist = ( 05712 )
foreach sevar ( ${selist} )
echo hp${sevar}
ping hp${sevar} 200 -n 2 > /dev/null
if ($status != 0) then
echo ABBRUCH hp${sevar}
else
foreach depotvar ( ${depotpath} )
remsh hp${sevar} /usr/sbin/swinstall \
-x autoreboot=false \
-x mount_all_filesystems=false \
-s ${depotvar}
end
endif
end
-----------------------
If I try on a Client, it works fine:
swinstall -s 10.xxx.x.xxx:/var/spool/sw/hpux11_800/SSH \*
Peter Lachnitt
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-22-2005 09:23 PM
06-22-2005 09:23 PM
Re: swinstall script problem
Hi peter,
Following is the abstract of man swinstall:
Install all the software from local depot /tmp/sample.depot.1, using
any response files generated by request scripts:
#swinstall -s /tmp/sample.depot.1 -x ask=true \*
Try this, for more information refer man pages of swinstall.
Cheers!!!
eknath
Following is the abstract of man swinstall:
Install all the software from local depot /tmp/sample.depot.1, using
any response files generated by request scripts:
#swinstall -s /tmp/sample.depot.1 -x ask=true \*
Try this, for more information refer man pages of swinstall.
Cheers!!!
eknath
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-22-2005 11:15 PM
06-22-2005 11:15 PM
Re: swinstall script problem
Hi Peter,
If you don't want interactive session, then you need to specify
'-x patch_match_target=true'
as one of swinstall option.
-Amit
If you don't want interactive session, then you need to specify
'-x patch_match_target=true'
as one of swinstall option.
-Amit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-23-2005 12:30 AM
06-23-2005 12:30 AM
Solution
I think you;ve mixed up csh commands with ksh. foreach is a C shell construct. It is particularly difficult to run multiple shells. Because csh is so incompatilbe with POSIX shells such as ksh, bash and HP's sh, it is recommended to do all sysadmin work in a POSIX shell, preferably /usr/bin/sh which is HP's POSIX shell. And in ALL cases, place the interpreter name as line number 1:
#!/usr/bin/sh
for all shell scripts.
The example that works on the client is nothing like the remsh version. On the client, use the command you're trying to run with remsh:
/usr/sbin/swinstall -x autoreboot=false -x mount_all_filesystems=false -s /your_depot_fullpath
and you'll see that it fails. swinstall requires that you specify exactly what parts of the depot you want to load--there is no default, so in the manual command, you supplied this value: \* where the star says load all. So you must add the \* to remsh, BUT with the star, you now have a shell special character, so enclose the entire remsh string in quotes:
remsh hp${sevar} "/usr/sbin/swinstall -x autoreboot=false -x mount_all_filesystems=false -s /your_depot_fullpath \*"
And finally, you can trace the steps of your script with the -x option. Just insert this the interpreter line:
set -x
Bill Hassell, sysadmin
#!/usr/bin/sh
for all shell scripts.
The example that works on the client is nothing like the remsh version. On the client, use the command you're trying to run with remsh:
/usr/sbin/swinstall -x autoreboot=false -x mount_all_filesystems=false -s /your_depot_fullpath
and you'll see that it fails. swinstall requires that you specify exactly what parts of the depot you want to load--there is no default, so in the manual command, you supplied this value: \* where the star says load all. So you must add the \* to remsh, BUT with the star, you now have a shell special character, so enclose the entire remsh string in quotes:
remsh hp${sevar} "/usr/sbin/swinstall -x autoreboot=false -x mount_all_filesystems=false -s /your_depot_fullpath \*"
And finally, you can trace the steps of your script with the -x option. Just insert this the interpreter line:
set -x
Bill Hassell, sysadmin
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP