Mental on Thu, 19 Apr 2001 17:10:08 -0400


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] TAR command line question


On Thu, Apr 19, 2001 at 02:59:14PM -0400, Chuck Peters wrote:
> On Thu, 19 Apr 2001, Bill Jonas wrote:
> 
> > $ tar cf - . |gzip -c - >file.tar.gz #Compress the file along the way
> 
> GNU tar has compression built in, this does the same thing.
> tar czf . file.tar.gz    
> 

Actually, it just forks and execs gzip for you. But thats irrelevent.

Compressed tape archives are generally a bad idea.

Usually when you're writing data to tape, its to back it up.
Generally speaking, you'll want maximal reliability in your backups. Its
very difficult to recover a compressed tape if there's bad blocks on the 
tape. With uncompresses archives on tape, you can usually get to the next
file and get the rest of the data on the tape. 

The info page comments about this in the compression/gzip  section:

   About corrupted compressed archives: `gzip''ed files have no
redundancy, for maximum compression.  The adaptive nature of the
compression scheme means that the compression tables are implicitly
spread all over the archive.  If you lose a few blocks, the dynamic
construction of the compression tables becomes unsynchronized, and there
is little chance that you could recover later in the archive.


Having been bitten by this, and the previously mention absolute path bug 
(starting the backup with a '/') under solaris I can say that it is
extreemly frustrating when it happens. Especialy when it was someone else
running the backups you're trying to recover from.... 

Since this originally started out as a using tar to backup to tape thread
I thought I'd share.

--
Mental


______________________________________________________________________
Philadelphia Linux Users Group       -      http://www.phillylinux.org
Announcements-http://lists.phillylinux.org/mail/listinfo/plug-announce
General Discussion  -  http://lists.phillylinux.org/mail/listinfo/plug