The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Airfoil Speakers for Linux 1.0.0 (Default branch) iBot Software Releases - RSS News 0 04-07-2008 09:40 PM
tar and gzip tungaw2004 UNIX for Dummies Questions & Answers 3 06-22-2007 12:21 AM
tar/gzip/gz...which one to use? abhijeetkul UNIX for Advanced & Expert Users 5 03-24-2006 12:00 AM
TAR and GZIP help VandeMatram UNIX for Dummies Questions & Answers 3 03-17-2006 04:35 AM
gzip alisevA3 UNIX for Dummies Questions & Answers 2 08-12-2004 08:29 AM

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1  
Old 06-15-2007
Registered User
 

Join Date: Nov 2006
Posts: 23
Using gzip and my speakers have gone mad!

Hello,

I wanted to compress a directory which I did with:
Code:
tar -czvf backup15062007.tar.gz backup15062007/
I knew that you could specify the compression level with gzip so I then did:
Code:
gzip -cvf9 backup15062007.tar.gz backup15062007compress.tar.gz
Now I know this probably won't work )it's a 1.3GB file and still going in the background) as I'm trying to compress a file that's already compressed (with tar -z), and it's now producing output on the screen that's just complete rubbish, with umlauts and so forth, but the thing is that my speaker has gone mad. I'm using cygwin on windows XP, and the default 'ding' is playing about four times a second almost non-stop whilst the compression is going. But there are no messages on the screen other than the console window output.

Why is this?

Thanks.

H.
Reply With Quote
Forum Sponsor
  #2  
Old 06-15-2007
Ygor's Avatar
Moderator
 

Join Date: Oct 2003
Location: -31.96,115.84
Posts: 1,248
You are uncompressing to standard output, i.e. your screen.
Code:
$ gzip --help
gzip 1.3.5
(2002-09-30)
usage: gzip [-acdfhlLnNrtvV19] [-S suffix] [file ...]
 -a --ascii       ascii text; convert end-of-lines using local conventions
 -c --stdout      write on standard output, keep original files unchanged
 -d --decompress  decompress
 -f --force       force overwrite of output file and compress links
 -h --help        give this help
 -l --list        list compressed file contents
 -L --license     display software license
 -n --no-name     do not save or restore the original name and time stamp
 -N --name        save or restore the original name and time stamp
 -q --quiet       suppress all warnings
 -r --recursive   operate recursively on directories
 -S .suf  --suffix .suf     use suffix .suf on compressed files
 -t --test        test compressed file integrity
 -v --verbose     verbose mode
 -V --version     display version number
 -1 --fast        compress faster
 -9 --best        compress better
    --rsyncable   Make rsync-friendly archive
 file...          files to (de)compress. If none given, use standard input.
Reply With Quote
  #3  
Old 06-15-2007
Registered User
 

Join Date: Nov 2006
Posts: 23
I don't follow, surely:

Code:
gzip -cvf9 backup15072007.tar.gz backup15062007compress.tar.gz
is forcibly compressing the initial file (already compressed) with a compression level of 9 and printing the stats in verbose mode to the screen, but compressing to a file (the second filename listed)?

Why then does that have anything to do with the speakers? The command ran for an hour before I stopped it - the 'dings' were driving me mad.

H.
Reply With Quote
  #4  
Old 06-15-2007
solfreak's Avatar
Registered User
 

Join Date: Jun 2007
Posts: 35
Quote:
Originally Posted by patwa
I don't follow, surely:

Code:
gzip -cvf9 backup15072007.tar.gz backup15062007compress.tar.gz
is forcibly compressing the initial file (already compressed) with a compression level of 9 and printing the stats in verbose mode to the screen, but compressing to a file (the second filename listed)?

Why then does that have anything to do with the speakers? The command ran for an hour before I stopped it - the 'dings' were driving me mad.

H.
When you send the binary output of gzip (a lot of unprintable chars and some terminal control commands) to stdout the terminal beeps in protest.

Try: gzip -cvf9 backup15072007.tar.gz > backup15062007compress.tar.gz

Another thing, compressing a gzip file again will not save any disk space and you will be spending twice the amount of time compressing and extracting the archive.
Reply With Quote
  #5  
Old 06-15-2007
Registered User
 

Join Date: Nov 2006
Posts: 23
Ah, I get it now, missed the > sign.

BTW, I had to remove the previously corrupted archive, but:
Code:
rm -vf backup15062007.tar.gz
does not work. It says "Removed backup15062007.tar.gz" but it still shows up in the directory listing.

Thanks.

H.
Reply With Quote
  #6  
Old 06-15-2007
Registered User
 

Join Date: Nov 2006
Posts: 23
Fixed with a restart.

Thanks again.

H.
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 02:17 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0