Simpler Navigation for Servers and Operating Systems - Please Update Your Bookmarks
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
If you have bookmarked forums or discussion boards in Servers and Operating Systems, we suggest you check and update them as needed.
General
cancel
Showing results for 
Search instead for 
Did you mean: 

compress and/or gzip problem on HP-UX 11.0

Dee_3
Regular Advisor

compress and/or gzip problem on HP-UX 11.0

Hi-
I have an 11.00 HP-UX system that I am loading an application onto from the hp-ux 11.0 application cd. I created a tar ball of these files and then wanted to compress or gzip this info to send to another system as well (a system that does not have an attached cdrom device). When I run compress terri.tar the system appears to be executing the command and returns to a # sign, but does not create the terri.tar.Z file. I've tried compressdir and also gzip. gzip created a file of very similar size, which is very large. I even downloaded the version of gzip for large files with no change. Can someone help? Thanks, Terri Christensen.
6 REPLIES
Sridhar Bhaskarla
Honored Contributor

Re: compress and/or gzip problem on HP-UX 11.0

Hi Terri,

If the file that you want to compress is already a compressed one, then compress cannot compress it further.


You can reproduce the above by compressing few files, tar them up and then try to compress the tar bundle.

Use -v option to get more information.

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

Re: compress and/or gzip problem on HP-UX 11.0

Hi Terri,

What happens when you try:

compress -v terri.tar

Also, can you do an:

echo $?

right after the compress to see if it gives back a return code? That might give a clue. Another thing to check is disk space. You'll need a good bit of free space to compress the file. How big is terri.tar, and how much free space do you have on the filesystem where you are trying to compress it?

JP
benoit Bruckert
Honored Contributor

Re: compress and/or gzip problem on HP-UX 11.0

Hi,
files from the application CD are already compressed.
the fact to tar them will just place them in 1 file. And a second compress will not change anything !

The best way to install software is to share trough NFS your cdrom device, and read it directly from the other host.
This is what I do from my pc, because I don't want to go to the machine room to open the cdrom drive !!!!!

hope that help
Benoit
Une application mal pansée aboutit à une usine à gaze (GHG)
Hamdy Al-Sebaey
Regular Advisor

Re: compress and/or gzip problem on HP-UX 11.0

Hi Terri,
To compress a file I used this command,

# gzip -cd new.gz |gzip > new1.gz

regards,
Hamdy
Thanks for sharing knowledge
T G Manikandan
Honored Contributor

Re: compress and/or gzip problem on HP-UX 11.0

#tar cvf /home/files.tar ./*
#compress /home/files.tar

#tar cvf /home/files.tar
#gzip /home/files.tar



Also you can do a

tar cvf - /path | remsh "cd ; tar xvf -"

Make sure that the remsh works on the remote machine

Also you can do a

rcp -r /path/ :/xxx/path


Thanks
Vincent Farrugia
Honored Contributor

Re: compress and/or gzip problem on HP-UX 11.0

Hello,

By default, the compress command deletes the .Z file if it finds that it is larger than the original file.

The LZW algorithm used by "compress" can expand the file instead of compress it if it is already compressed.

Gzip creates the file anyway, that's why you have the big file.

If files are already compressed, compressing them further would do no good, actually, you'll expand the files.

HTH,
Vince
Tape Drives RULE!!!