1830497 Members
2407 Online
110006 Solutions
New Discussion

about gunzip

 
thebeatlesguru
Regular Advisor

about gunzip

[root@dbbak-lc:/var/opt/omni/log]#cat omnisv.log | gunzip >new.log

gunzip: stdin: not in gzip format

why gunzip doesnt work?
what should i do
hihi
9 REPLIES 9
Deepak Extross
Honored Contributor

Re: about gunzip

What does
file omnisv.log
show?
Sanjay_6
Honored Contributor

Re: about gunzip

Hi,

What are you trying to do. Gunzip is to unzip a compressed file.

Hope this helps.

Regds
Deepak Extross
Honored Contributor

Re: about gunzip

To compress a file
gzip
This will automatically rename as .gz after compressing.

To uncompress a file
gunzip .gz
Note that you can only 'gunzip' a file which had been 'gzip'ed earlier!
harry d brown jr
Honored Contributor

Re: about gunzip

thebeatlesguru,

and the WORSE thing to do is to use CAT to pipe a file to any kind of archiving product. If you must use that kind of format, use "dd"::>

dd if=infile | gzip > somefilename

"cat" screws with carriage returns and control characters!

It's one command I wish would go away! Yeah, ok, fine, I'm not a "cat" lover, but I have to live with my wife's cat, and she's bad enough (the cat - that is)!

live free or die
harry
Live Free or Die
Roger Baptiste
Honored Contributor

Re: about gunzip

<new.log>>

One of the right ways is:

#gunzip omnisv.log

This will zip omnisv.log to omnisv.log.gz
in the same directory.

HTH
raj
Take it easy.
Roger Baptiste
Honored Contributor

Re: about gunzip

<new.log>>

One of the right ways is:

#gunzip omnisv.log

This will zip omnisv.log to omnisv.log.gz
in the same directory.

HTH
raj
Take it easy.
Roger Baptiste
Honored Contributor

Re: about gunzip

Instead,
#gzip omnisv.log will work.
It will zip the file to omnisv.log.gz .

HTH
raj
Take it easy.
Wodisch
Honored Contributor

Re: about gunzip

Hello,

if you go for the "gzip|omnisv.log" approach make sure that Omniback is NOT running any more, and "mv" the file to another place, afterwards, before restarting Omniback again!

Just my $0.02,
Wodisch
thebeatlesguru
Regular Advisor

Re: about gunzip

i just wanna know how to use this command
Alexander M.Ermes write:
"If you have zipped a file and the zipped file is larger than 2 GB, usually you cannot unzip it.
Here a workaround :

cat file | gunzip > new_file

We use this, when we have zipped ORACLE exports on the flight and want to import these data.
Rgds
Alexander M. Ermes "

hihi