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 09:28:21 -0500
User-agent: Thunderbird 2.0.0.23 (X11/20090825)

Sergey Poznyakoff wrote:
Hi Bdale,

When creating incremental backups using snapshot filesystems, tar fails
to include files in a level 1 backup (presumably any level > 0) if they
were modified in the original filesystem between the time the snapshot
was created and the time the level 0 backup was created of the
snapshot.

Yes, it is a known fact. There is a certain lapse of time between a
file is registered in the incremental snapshot and actually archived.
If it changes in between, these changes are not stored in the snapshot.
That's not the bug reported by Bdale.
He backup a snapshot filesystem, there is no change in the filesystem during the backup, the change are made in the original filesystem. The change made between the filesystem snapshot creation and the backup time will not be included in the next higher level backup.
It is a major bug for all users that use filesystem snapshot to make backup.

I have had a look at the source, and the cause seems to be that the option
newer_mtime_option is set from the creation time of the previous incremental
archive (in incremen.c:read_incr_db_01 and incremen.c:read_incr_db_2)
While I can't think of any good reason to set this option at all, except as a
(failed) attempt to avoid unnecessary work, I cannot assess the full
impact of simply removing the code in question.

The full impact of this would be rendering the incremental backup code
completely inoperational and useless: tar's incremental backups are
based on comparing file's mtimes with the reference timestamp stored in
the snapshot file.

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?

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

Jean-Louis




reply via email to

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