Do tar verify binary conformity (something like md5sum) original files with that it put in archive file?
Thanks in advance,
os
> Do tar verify binary conformity (something like md5sum) original
> files with that it put in archive file?
$ tar --help | grep verify
-W, --verify attempt to verify the archive after writing it
That checks at the time it's writing it. It doesn't store the hash in
the archive, so if the file is corrupted in transit it won't detect it.
--
Barry Margolin, bar...@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
*** PLEASE don't copy me on replies, I'll read them in the group ***
But I can do:
1. create tar and verify (on the same machine) - for example xyz.tar
2. md5sum xyz.tar
3. transit xyz.tar to other machine and md5sum xyz.tar
4. if sum from 3. and 4. are equal then I have xyz.tar NOT corrupted on other machine
Is it correct?
Yes, you could also do:
tar cf - /some/dir | tee xyz.tar | md5sum
In case xyz.tar would get corrupted on the local filesystem (but
then files in /some/dir might be corrupted as well).
--
Stéphane