1835377 Members
3236 Online
110078 Solutions
New Discussion

Re: swcopy to a bundle

 
SOLVED
Go to solution
BIHAN
Frequent Advisor

swcopy to a bundle

Hello,
I can't figure how to copy patches or software to a depot so they are all grouped in a bundle. It seems that swcopy can only target to a direcory or a depot.

Any ideas ?

Thanks

Emmanuel
10 REPLIES 10
Sanjay_6
Honored Contributor

Re: swcopy to a bundle

Hi,

you'll have to use the "swpackage" command to create a single depot file in which you can package a bunch of patches.

Hope this helps.

Regds
Pete Randall
Outstanding Contributor

Re: swcopy to a bundle

Emmanuel,

You might want to look into the swpackage command. According to the man page, "swpackage can be used to re-package software_selections from an existing distribution directory".


Pete

Pete
Zygmunt Krawczyk
Honored Contributor

Re: swcopy to a bundle

Hi,

hope this help:

Creating a Patch Depot
Follow these steps to create a patch depot on an HP-UX system.
Step 1. Obtain the set of patches you want to place and manage in an SD depot.
For example:
PHCO_7891 PHCO_9348 PHKL_9361 PHSS_7726 PHSS_8966 PHSS_9400
PHCO_8353 PHKL_8376 PHKL_9569 PHSS_8667 PHSS_9201
HP Patches delivered by the Response Center or the Web are shar files
consisting of a serial depot and a ReadMe file.
Step 2. Unshar the patches using:
for i in PH*
do
sh $i
done
Step 3. Combine the separate depots into one depot:
1. Create a directory to store the patches:
mkdir /var/opt/ignite/Patches
2. Copy the individual patch depots into your depot:
for i in PH*.depot
do
swcopy -s ${PWD}/$i -x enforce_dependencies=false \* @ /var/opt/ignite/Patches
done
Step 4. Verify the contents of the depot directory:
swlist -d @ /var/opt/ignite/Patches
5. Convert the directory into depot (tape image)
swpackage -s /var/opt/ignite/patches -x enforce_dependencies=false \* @ /var/opt/ignite/patches.depot
6. Verify depot of patches
swlist -s /var/opt/ignite/patches.depot

Regards,
Zygmunt
Sanjay_6
Honored Contributor

Re: swcopy to a bundle

Hi,

Here is a n example from itrc.

http://www2.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000066937439

the itrc doc id is HONCIKKBRC00000015.

If you want to create a single depot file on the disk itself you have to specify the same with -d switch in the "swpackage" command. Also remember that there is a switch called layout_version (i think) with the swpackage command if you are messing with depots for multiple versions of the Operating System.

Hope this helps.

Regds
Zygmunt Krawczyk
Honored Contributor

Re: swcopy to a bundle

Sorry, my mistake,
step 5 should look like this:

swpackage -s /var/opt/ignite/Patches -x media_type=tape @ /var/opt/ignite/patches.depot
BIHAN
Frequent Advisor

Re: swcopy to a bundle

thank you all for the quick answer
but i realise my question was not clear, sorry.

I give an example
inside the same depot.
i put one software (a "product") and the associated patches.
I want the patches grouped so when opening the depot there is only two lines displayed, one for the software and one for all the patches .

I have read the swpackage manpage.
(i'll take aspirine )

I am not sure swpackage is suitable for this purpose or maybe is it possible to extract a "psf" file from an existing depot and to repackage after changing the "psf" file ?

BIHAN
Frequent Advisor

Re: swcopy to a bundle

thank you all.
i'll continue to search,
if i find the answer
i'll post it here

Regards

Emmanuel
Eric Antunes
Honored Contributor

Re: swcopy to a bundle

See this thread:

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=675021

May be it'll help.

Regards,

Eric Antunes
Each and every day is a good day to learn.
Zygmunt Krawczyk
Honored Contributor
Solution

Re: swcopy to a bundle

Hi,

below is the procedure to make a bundle from individual patches:

Step 1. Convert the individual patches into a single bundle and put the bundle
in the patches depot directory:

make_bundles -B -n Misc_Patches \
-t "HP-UX 11.11 Patches" /var/opt/ignite/Patches

Step 2. Run swlist on this depot to verify that the bundle has been created:

swlist -d @ /var/opt/ignite/Patches

Following is the output for the example patches:

Initializing...
Contacting target "hpserver"...
Target: hpserver:/var/opt/ignite/Patches
Bundle(s):
Misc_Patches HP-UX 11.11 Patches

By default, swlist shows only the higher level software bundles. This
command shows the patch "products" contained in the bundle:

swlist -l product -d @ /var/opt/ignite/Patches

If you need to add additional patches to the depot in the future, simply
unshar the patches as described above, swcopy them into the Patches
depot, and rerun make_bundles. This will repackage the depot.

If you would like to remove a patch from the depot, simply use the
swremove command. You can either run swremove and use its friendlier
user-interface, or run swremove in command-line mode. This example
removes the PHKL_8376 patch from the depot:

swremove -d Misc_Patches.PHKL_8376 @ /var/opt/ignite/Patches

Good luck,
Zygmunt
BIHAN
Frequent Advisor

Re: swcopy to a bundle

Thank you, makes_bundles works great.

For the people who are looking for this tool, it comes with ignite, path is /opt/ignite/bin/make_bundles.



Emmanuel