Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: Has foo.tar.bz2 been extracted to $dirrectory?

by bluto (Curate)
on Nov 01, 2002 at 17:12 UTC ( [id://209787]=note: print w/replies, xml ) Need Help??


in reply to Has foo.tar.bz2 been extracted to $dirrectory?

- foo.tar.bz2 has been download completely

The '-t' or '--test' flags of bzip2 check the integrity of the compressed file. If there is an MD5 checksum, you can generate and compare that as well. I'm assuming GNU tar, which you may be using(?), will do this with the 'j' flag, though you may want to test for this.

- foo.tar.bz2 has been untared completely

Some tar's will remain silent and appear to untar files on filesystems that run out of space (and create zero length files to boot). Gnu's tar has a '--compare' option which I've never used but might be worth a try. If you aren't using Gnu tar, you'll probably need to examine the contents of the archive yourself (e.g. tar -tv).

bluto

Replies are listed 'Best First'.
Re^2: Has foo.tar.bz2 been extracted to $dirrectory?
by Aristotle (Chancellor) on Nov 02, 2002 at 07:22 UTC
    I don't see a --compare in my manpage, but there is a -W / --verify.

    Makeshifts last the longest.

Re: Re: Has foo.tar.bz2 been extracted to $dirrectory?
by Spida (Acolyte) on Nov 02, 2002 at 11:43 UTC
    The idea to use "--compare" is not practical for me since that would decompress and untar the whole archive again, compare it, and delete the temporay extracted archive. Thats because of the size of the archive and because of the resources not possible.
    OTOH bzip2 -t foo.tar.bz2 works fast and fine *g*.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://209787]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (4)
As of 2024-03-29 00:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found