bug-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-tar] --listed-incremental ignores changed files when using file


From: Jean-Louis Martineau
Subject: Re: [Bug-tar] --listed-incremental ignores changed files when using filesystem snapshots
Date: Sun, 15 Nov 2009 11:59:14 -0500
User-agent: Thunderbird 2.0.0.23 (X11/20090825)

I already found the documentation and found that the files mtime are in in the snapshot file, and so there is no easy fix.

A temporary workaround could be to change the mtime in the snapshot file with the time of the creation of the filesysytem snapshot.

Jean-Louis

Sergey Poznyakoff wrote:
Jean-Louis Martineau <address@hidden> ha escrit:

It is a major bug for all users that use filesystem snapshot to make backup.

I did not argue whether this could be considered a bug or not. I only
described the way tar works.

What is the reference timestamp stored in the snapshot file? Is it
 - the time the backup started?
 - the time when the file was put in the archive?
 - the mtime of the file when it was put in the archive?

The first. It is documented in the Tar Manual, Appendix D.

Each file's mtime is compared with the time  the previous backup
was created. In the case reported by Bdale, the actual file's mtime
happens to be older than that, so it is not considered for the next
backup.
Let T be the time of mounting mnt-snap (line 26 of the script), in
seconds. Then, in this testcase, approximate mtimes of the `somefile'
before creating level-0 backup file will be:

Backup creation time T+4 ./mnt-snap/somefile mtime T-1
  ./mnt/somefile mtime       T+3

At the time of level-1 backup, tar notices that somefile is one second
younger than the level-0 backup and therefore does not archive it.

A file should be in the incremental if its mtime is newer than any of
these.

Right. This would imply a major (or even complete) rewrite of the
incremental backup support. That's why I said that I could not propose
any immediate solution. FWIW, I can get to rewriting the incremental code
only after releasing version 1.23, which is scheduled to the end of
November.

Regards,
Sergey










reply via email to

[Prev in Thread] Current Thread [Next in Thread]