4

I made an incremental backup about 10 months ago (on Jan 27, 2013), creating a .snar metadata file. Now, when I try to make an incremental backup using

tar --create --file=dropbox_incremental_1.tar --listed-incremental=dropbox_0.snar Dropbox

the command just re-backs up everything.

I'm not an expert at Unix timestamps, but I noticed that virtually all of my directory timestamps are way more recent than the last time they changed. For my actual files, they look like this:

Access: 2013-03-12 19:04:51.000000000 -0500
Modify: 2012-09-30 15:10:47.000000000 -0500
Change: 2013-03-12 19:04:51.306209672 -0500

The 'Modify' timestamp seems correct, but the files were definitely not changed (at least not doing anything that I know of) at the time they say they were. These files still seem to go into the incremental archive.

What's happening here? Is there a way to tell tar to look at the 'modify' timestamp? Isn't this what it's supposed to be doing?

  • I would also make a backup more often than once every 10 months. – Michael Hampton Nov 8 '13 at 16:02
0

You didn't mention the filesystem/device type, but you could try:

$ tar --create --no-check-device --file=dropbox_incremental_1.tar --listed-incremental=dropbox_0.snar Dropbox

Also see Fixing Snapshot Files.

| improve this answer | |
0

Tar looks mtime indeed. But It should also look ctime as well since it processes file's metadata (e.g. permissions).

My guess is your dropbox application uses ctime for its own purposes and nothing you can do with it.

UPD:

You may use update option -u instead of incremental mode. It seems to ingnore ctime.

| improve this answer | |
0

Ultimately I couldn't find a way to get --listed-incremental working with Dropbox. I'm guessing, as Veniamin said, tar looks at both ctime and mtime. Dropbox must do something that touches ctime, so it just causes the entire archive to get backed up each time I run it.

Instead, I just did tar --create --file mybackup.tar --newer-mtime="26 Jan 2013" Dropbox

While it's not quite as slick as the incremental backup, I'm happy with it, as it should get all the files that have changed (based on mtime) since my last backup. In this case, this backup is a third backup, so if something happens where I'm reaching to this one, I'll be happy to just have the files and dealing with a not-perfectly-slick system will be fine.

Thanks for your responses.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.