Operating System - HP-UX
1832487 Members
4206 Online
110043 Solutions
New Discussion

"tar" command hit errors.......

 
SOLVED
Go to solution
Chris Fung
Frequent Advisor

"tar" command hit errors.......

Hi all,

I just encountered a quite strange things that my backup script in which I use "tar" command to backup filesystems everyday. It runs fine for almost 2 months and today, there is an error popped up that....it said:

Quote:

a ./crm/app/log/dr_tape_Sun.ltar: 0511-173 File ./crm/app/log/dr_tape_Sun.log is not of the expected file size

Unquote:

The dr_tape_Sun.log is the backup log file which stores the standard output and errors for the backup tar program. The error to me seems the file size for the dr_tape_Sun.log has been changes along with the backup job, therefore there is a discrepancy between the tar index and the actual file size.

However, if my assumption is correct, this error should be popped up everyday, not just today.....that's why I am writing to seek help from U genius.

Thanks in advance,

Cheers,

Chris,

2 REPLIES 2
doug hosking
Esteemed Contributor
Solution

Re: "tar" command hit errors.......

All it really means is that tar has noticed
that the file changed size during the backup -
that would be perfectly reasonable in the
case of a log file for an active backup.

As for why it happens some days and not others, it could depend on timing or buffering of the log file. Chances of hitting this message would presumably be lower if you did not use the 'v' option on tar. (If you're going to create a log of what's on the backup, it may be smarter to create the backup without the v option, so you get errors but not the names of the files on the tape, then do a 'tar tv' to verify that you have a readable tape. This takes longer but gives you more assurance you have a reliable backup.)

You could avoid the message entirely if you could put the log in a different directory than one that is being backed up. In any case, i don't think this message is something you should worry about if it's just for the backup
log file.

If you see that message on something like a
database file, you would have more reason to be
concerned, because it would suggest that you
are getting an inconsistent copy of the
database. That's the real purpose of the message.

Ceesjan van Hattum
Esteemed Contributor

Re: "tar" command hit errors.......

Tar just first wants to make an index and the files in thi index will be tarred. The change of a difference in files is always there, but it can take weeks to get a negative hit.
Exclude the file of the tar.
Mind that this can also happen to other files: /var/adm and others.

But really, i would prefer fbackup and frecover.

Regards,
Ceesjan