- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- corrupt tar file
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-24-2007 11:57 PM
тАО05-24-2007 11:57 PM
a developer here has created a tar file and compressed it by running the following command:
tar cvf - * |compress -c > tarfile.Z
to uncompress the file he runs:
cat tarfile.Z |uncompress |tar xvf -
the issue is when he attempts to uncompress the file there is an error:
tar: 0511-169 A directory checksum error on media; 0 not equal to 8692.
Ok so some tests I attempted:
I uncompressed the file and ran the file command:
--> file dtr01datafiles_BCK.tar
dtr01datafiles_BCK.tar: data or International Language text
states not a tar file.
I ran through the compress and uncompress process and this was successful.
The developer has assured me he has been compressing the data using this method for some time and has managed to uncompress the data in the past.
The actual file created is 44GB and when compressed is 8gb.
does anyone have any idea's how we can recover the data?
Thanks
Chris
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-25-2007 01:13 AM
тАО05-25-2007 01:13 AM
Re: corrupt tar file
Are you archiving/extracting on the same system, or two systems (same OS or different OSes)? If two, are you using different versions of tar? What does 'cksum tarfile.Z' on each end tell you?
Where is the compressed tarball being stored? Disk? Tape? DVD-ROMs?
Does tar still complain if you forgo compressing/uncompressing the tarball? How about if you use gzip (http://hpux.connect.org.uk/hppd/hpux/Gnu/gzip-1.3.12/) instead of compress?
PCS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-25-2007 02:16 AM
тАО05-25-2007 02:16 AM
Re: corrupt tar file
tar cvf - /etc/a* | compress -c > etc.tar.Z
zcat etc.tar.Z | tar tvf -
I agree that compress should be replaced by another compression utility.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-25-2007 03:23 AM
тАО05-25-2007 03:23 AM
Re: corrupt tar file
1983363346 8311147750
so this is inconsistant ...
zcat dtr01datafiles_BCK.tar.Z |tar tvf -
tar: 0511-169 A directory checksum error on media; 0 not equal to 8692.
I think we can determine that the tarfile has become corrupt and I don't like the use of -c in this case.
I have suggested they use:
tar cvf - * |gzip > file.tar.gz
and to recover
gunzip < file.tar.gz |tar xvf -
Thanks for the help, but any suggestions on how to recover the data from the corrupt tarfile?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-25-2007 03:29 AM
тАО05-25-2007 03:29 AM
Solutionhttp://www.tar-repair.com/
Note that I have never used this product, so I can't speak to its effectiveness.
Unfortunately, even in the best case, you will experience data loss.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-25-2007 11:24 AM
тАО05-25-2007 11:24 AM
Re: corrupt tar file
$ zcat tarfile.Z | xd -tx4 -tc -N 2048
Or if you still have it:
$ xd -tx4 -tc -N 2048 dtr01datafiles_BCK.tar
You then can match it up with tar(4).
http://docs.hp.com/en/B2355-60103/tar.4.html
>The actual file created is 44GB
I'm not sure if gzip handles large files yet? I suppose you could use cat and a pipe.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-25-2007 03:43 PM
тАО05-25-2007 03:43 PM
Re: corrupt tar file
defined error message ("0511-169 [...]")
that you're actually working on an AIX
system? (In which case, asking in an HP-UX
forum may not be the most efficient way to
access relevant expertise.)
You're running large-file-sized data sets
(>2GB) through multiple programs which might
have trouble with large files. The data
could be corrupted in almost any step in the
process.
As others have suggested, "cat" with a pipe
may work better with some programs than
asking those programs to read directly from a
(large) file.
It might be helpful to get a clearer
explanation of exactly what was done where,
and if any files were transferred from one
system to another (and how), but my guess is
that you'll need to back up and see what the
limitations (file size and other) are for the
programs you're using on the systems where
you're using them.
> does anyone have any idea's [...]
Those are "ideas" (no apostrophe).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-26-2007 03:59 AM
тАО05-26-2007 03:59 AM
Re: corrupt tar file
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-29-2007 07:30 PM
тАО05-29-2007 07:30 PM
Re: corrupt tar file
The file is corrupt on the system where the file was created.
Chris.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-29-2007 07:52 PM
тАО05-29-2007 07:52 PM
Re: corrupt tar file
> across all systems.
Presuming is often unsafe.
"Similar" is a technical term meaning "not
identical".
This sort of thinking may lead to confused
behavior, such as posting AIX questions in an
HP-UX forum.
In fact, there are many "tar" programs in the
world, each similar to and different from all
the others, in ways which may be important or
not.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-29-2007 08:12 PM
тАО05-29-2007 08:12 PM
Re: corrupt tar file
if you have a problem with me posting generic unix questions in this forum then please do not respond ....
I use this forum because:
1> I find it the best for a quick and accurate response to most questions
2> People don't usually get hung up that I work on AIX ( I worked on HP for over 4 years )
I can appreciate your comments however what people have posted in this thread has help me come to my conclusion.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-30-2007 09:55 AM
тАО05-30-2007 09:55 AM
Re: corrupt tar file
If you are using AIX, you must say so in every thread. This will prevent confusion and possibly wrong answers.