Operating System - HP-UX
1832993 Members
4091 Online
110048 Solutions
New Discussion

Re: how to swinstall two different package based on two diff clients

 
Hanry Zhou
Super Advisor

how to swinstall two different package based on two diff clients

Hi,

I need to create a depot which include two packages, I want to swinstall to load one of package based on the situation(the output of a script) on the client. How do I achieve that?

Please let me know.

Thanks,
none
6 REPLIES 6
Steven E. Protter
Exalted Contributor

Re: how to swinstall two different package based on two diff clients

by script:

if [ criteria 1 ]
then
swinstall -s /full_path_of_depot depot_name1
fi

if [ criteria 2 ]
then
swinstall -s /full_path_of_depot depot_name2
fi

You have to define the criteria.

while read -r varname
do

done < input_file

comes to mind.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Hanry Zhou
Super Advisor

Re: how to swinstall two different package based on two diff clients

Steven,

Thanks for the message, but it is not exactly what I want to do.

I wanted to have the swinstall itself to make the dicison and load the appropriate depot onto the client, not as the script your showed which is has to be running on agents.

I 'm thinking using .PSF file when you create a depot, or one of steps to do pre- or post- scripts?

Thanks,
none
Hanry Zhou
Super Advisor

Re: how to swinstall two different package based on two diff clients

I can't believe few people answer's my message.
none
Sridhar Bhaskarla
Honored Contributor

Re: how to swinstall two different package based on two diff clients

Hi Hanry,

I would create a bundle with two products. Both products will have the checkinstall scripts. One checkinstall script fails and the other succeeds based on your situation. The product with the failing checkinstall script will be excluded from install.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Hanry Zhou
Super Advisor

Re: how to swinstall two different package based on two diff clients

Sridhar ,

No too much idea on what you are talking about, where I create two products, how to define the checkinstall, and what checkinstall is supposed to do? Can you please explore it a little bit more?
none
Sridhar Bhaskarla
Honored Contributor

Re: how to swinstall two different package based on two diff clients

Hi (Again),

That was assuming you were trying to create a depot yourself with swpackage command. Look at the following document on "Creating Software Packages" section.

http://docs.hp.com/hpux/onlinedocs/B2355-90789/B2355-90789.html

If not, then it is not possible to do it other than what SEP mentioned.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try