Gnu Tar 1.12 Incremental Bug Report


Message 1 of 2



From: Greg Ercolano <erco@sre.sony.com>
To: tar-bugs@gnu.ai.mit.edu
Subject: GNU TAR 1.12: incremental bug report
Date: Fri, 09 Oct 1998 14:23:00 -0700




Message 2 of 2



From: Greg Ercolano <erco@sre.sony.com>
To: tar-bugs@gnu.ai.mit.edu
CC: erco@netcom.com, Kay.Diederichs@uni-konstanz.de, spd@daphne.cps.unizar.es
Date: Mon, 12 Oct 1998 17:06:16 -0700
Subject: Re: GNU TAR 1.12: incremental bug report: bug identified?
[295 may also be a problem -erco]
The modify time for a file is *not* changed when it is renamed,
so this appears to be the cause of the problem. When the date
stamps are greater than, or especially equal, then the file is
backed up. This is why my test script works when there's no sleeps,
since the date stamps are THE SAME, failing the test in 293.

To correct the problem, if the modify time is LESS than the snapshot
file, but the filename is NOT in the list of files that have already
been backed up, then it SHOULD be backed up.

I do not have a fix, since I don't know all the ins and outs of
diving through the snapshot file.

INCREMENTAL TEST SCRIPT BUGS/ADDITIONS NEEDED
---------------------------------------------
Also, one problem is that the incremental test script is
NOT failing, and it should be.

[The following is striked out because I'm not sure I believe it anymore -erco]
One reason is there is only one sleep command in the script. 
To answer the question posed by the comment within that script:

--------
# FIXME: The sleep is necessary for the second tar to work.  Exactly why?
sleep 1
--------

The answer is (I think), that sleep command synchronizes the clock
so that, if the rest of the commands execute within a second, the bug
does not surface! That is one reason why the test passes. 

Several things should be added to the incremen.sh script to correctly
test gnutar incrementals:

    1) It should at LEAST do a 'sleep 1' (if not 'sleep 2') after EACH tar
       command, or any command that modifies the file system such as with 
       touch or rename.

    2) The test should include files that are *renamed* after the
       level0 backup, but before the incremental.

I hope these suggestions help you towards fixing this problem.

As it is, we here at Sony don't trust the incremental backups
for this reason until the bug is fixed.

--
Greg Ercolano - SDC Unix Systems Administrator    xxxx: (xxx)-xxx-xxxx
erco@sre.sony.com                                 xxxx: (xxx)-xxx-xxxx