General
cancel
Showing results for 
Search instead for 
Did you mean: 

How to modify existing SDUX Package

SOLVED
Go to solution
Ganesh Balraman
Regular Advisor

How to modify existing SDUX Package

Hi All,

We already have created a pacakge and we need to add some files into the existing package .

Can you pls help in executing the process of steps for repackaging.


Thanks
19 REPLIES
RUET
Regular Advisor
Solution

Re: How to modify existing SDUX Package

Don't you have the sources of your package (PSF file and bits ) ?

if yes just modify the source bits, increment the version in your PSF file and rerun swpackage

As I know, swpackage is not able to make an upgrade of and actual package
Dennis Handly
Acclaimed Contributor

Re: How to modify existing SDUX Package

>P R: swpackage is not able to make an upgrade of an actual package

Right. The most you can do is create a patch that will install a file after the original product is installed.
Bob E Campbell
Honored Contributor

Re: How to modify existing SDUX Package

If you do not have a psf file you can start with a "swlist -v" of the product and then read the swpackage(4) man page.

While I am personally fond of patches, they are a touch more complex.
Armin Kunaschik
Esteemed Contributor

Re: How to modify existing SDUX Package

Get Software Package Builder from software.hp.com (also included on current HP-UX install media)!
The software let's you open your depot and extract the PSF file.
You can also create new packages... there is a comprehensive help coming with it.

My 2 cents,
Armin

PS: Please assign points!
And now for something completely different...
RajuD
Frequent Advisor

Re: How to modify existing SDUX Package

please let me know what is psf file and what it cointains..what significat improvement we can acheive on this.
“Education is our passport to the future, for tomorrow belongs to those who prepare for it today.”
Dennis Handly
Acclaimed Contributor

Re: How to modify existing SDUX Package

Rajesh: let me know what is PSF file and what it contains.

Product Specification File (PSF)
See the following:
Creating a Product Specification File (PSF)
http://docs.hp.com/en/5992-5875/ch10s04.html
Product Specification File
http://www.docs.hp.com/en/5991-7462/ch02s04.html

>what significant improvement we can achieve on this.

If you don't know what it is, why are you asking about improvements?

>Armin: The software let's you open your depot and extract the PSF file.

Do you know how to do this besides using the GUI?
Bob E Campbell
Honored Contributor

Re: How to modify existing SDUX Package

Could you be more specific as to what you mean by package? Most of these answers are assuming this meant a complete creation of everything from individual files. Was this package simply a bundle that grouped other content together?
RajuD
Frequent Advisor

Re: How to modify existing SDUX Package

Hi Denies,

Thansk for the reply i will go through the document provided.
“Education is our passport to the future, for tomorrow belongs to those who prepare for it today.”
Armin Kunaschik
Esteemed Contributor

Re: How to modify existing SDUX Package

@Dennis: Each depot is a tar-file actually. So un-tar it and check catalog/INDEX. Voila.
You might need additional files and resources. This is when SPB gets pretty useful as reference.

My 2 cents,
Armin

PS: Please assign points if you find answers useful!
And now for something completely different...
Dennis Handly
Acclaimed Contributor

Re: How to modify existing SDUX Package

>Armin: Each depot is a tar-file actually. So un-tar it and check catalog/INDEX.

Why would I do this if I know the GUI will do it for me?
Armin Kunaschik
Esteemed Contributor

Re: How to modify existing SDUX Package

@Dennis: Because you were asking!?!?

>Do you know how to do this besides using the GUI?

Puzzled,
Armin
And now for something completely different...
Dennis Handly
Acclaimed Contributor

Re: How to modify existing SDUX Package

>Armin: Because you were asking!?

I was asking for a SPB command line option equivalent for a feature that is available in the GUI.
Armin Kunaschik
Esteemed Contributor

Re: How to modify existing SDUX Package

Ah... Ok.
Then what about tar -xvf .depot catalog/INDEX ? :-)
And now for something completely different...
Dennis Handly
Acclaimed Contributor

Re: How to modify existing SDUX Package

>Armin: Then what about tar -xvf .depot catalog/INDEX? :-)

Why would I want the INDEX file if I need a PSF? And I know there is a GUI tool that will provide one?
Bob E Campbell
Honored Contributor

Re: How to modify existing SDUX Package

I am not sure I want to encourage depot brain surgery. I do it rather often myself but only in cases of extreme need.

I might point out that:

1. There is an order to serial depots. I recommend using swcopy/swpackage rather than tar.

2. catalog/INDEX is only the master index. It gets rebuilt from the fileset level indicies.

3. I have been working with SD attributes for years and can still make some big mistakes. Working with a PSF and/or SPB very recommended.

4. Use swmodify. For simple changes of basic attributes you can tweak content in a supported way. Never tweak an INDEX when the attributes are swmodify-able.
Armin Kunaschik
Esteemed Contributor

Re: How to modify existing SDUX Package

@Bob: The question was only how to get a PSF out of a depot easily (as I understood). In this special case (and only this) it's OK to un-tar the INDEX file. Otherwise I completely agree with you.

My 2 cents,
Armin
And now for something completely different...
Dennis Handly
Acclaimed Contributor

Re: How to modify existing SDUX Package

>Armin: The question was only how to get a PSF out of a depot easily. In this special case (and only this) it's OK to un-tar the INDEX file.

Yes and SPB does that for you, so no need to look at the INDEX file.
(Thanks for mention of this handy tool.)
Ganesh Balraman
Regular Advisor

Re: How to modify existing SDUX Package

Hi All,

I have modified the existing psf and ran the package .

It is workign fine .

We need one more additional requirement as one directory needs to be created as part of this product.

How to include string in psf file for creating directory.

Apreciate the best repsone.

Thanks,
Ganesh
Bob E Campbell
Honored Contributor

Re: How to modify existing SDUX Package

There are two ways to create a directory. One is to create a configure script that can run any commands you would like (do not prompt for user input!).

The other way is exactly the same as your other files. The swpackage command will take an explicitly named directory or match "*" to directories being packaged. For example, for SWA my PSF might have:

product
tag SWAMin
[snip]
fileset
tag SWA-RUN
[snip]
configure CTRL_D/SWA/SWA-RUN/configure
directory ./opt/swa/lbin=/opt/swa/lbin
file swainv
file -m 0555 -o bin -g bin /tmp /opt/swa
file -m 0555 -o bin -g bin /tmp /opt/swa/lbin

This will add a fileset-level configure script as well as the file swainv to the package while controlling the directory ownership.

See the swpackage(4) man page for more information (use "man 4 swpackage" to