1829913 Members
3099 Online
109993 Solutions
New Discussion

wrong time stamp

 
Rushank
Super Advisor

wrong time stamp

We are using gnu tar to take backup of our oracle database on a N-class with 11.X
When I run tar -tv command to check the contents on tape it shows time stamp as " Dec 31 18:00 1969.

Two questions:
1. Why is this wrong date and how to resolve this.
2. What is the main difference between normal ux-tar and gnu-tar.?

Thanks

2 REPLIES 2
Vincent Fleming
Honored Contributor

Re: wrong time stamp

The date shown looks like the "start of time". Times are stored as integers, and there has to be a 0 time - a starting point. So, the time field in the archive is probably zero or something very close to it.

Why? I dunno. It could be lots of things.

The gnu tar is different that the standard UNIX tar, but uses a compatible (mostly) format. If you're trying to read a gnu tar archive with standard tar, then you may have problems - gnu can read standard tar archives, but when gnu creates the archive, it can make it unreadable by standard tar in many different ways - for example, you can have gnu tar compress the data automatically. A gnu compressed tar archive is not readable by standard tar.

Read the man pages for gnu tar for details on what's compatible and what's not.

To avoid problems, you should always use the same version everywhere - you may want to just replace the standard tar program with the gnu version so that you always get the gnu tar.

Good luck
No matter where you go, there you are.
linuxfan
Honored Contributor

Re: wrong time stamp

Hi Rushank,


Not sure why the timestamp is showing incorrectly. what happens when you extract the files? Just curious do the timestamp show up incorrectly both with gnu tar and hpux tar?

Here is a link, which gives a good idea between the differences

http://www.gnu.org/manual/tar-1.12/html_chapter/tar_8.html#SEC112

-Regards
Ramesh
They think they know but don't. At least I know I don't know - Socrates