[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Duplicity-talk] Restoring a deleted file when not knowing, when it
From: |
Alexander Skwar |
Subject: |
Re: [Duplicity-talk] Restoring a deleted file when not knowing, when it was deleted |
Date: |
Mon, 07 May 2007 14:46:12 +0200 |
User-agent: |
Thunderbird 2.0.0.0 (X11/20070419) |
Kenneth Loafman schrieb:
> Alexander Skwar wrote:
>> Hello.
>>
>> I'm having a look at Duplicity 0.4.2 to backup my server. One thing I
>> did not yet figure out is, howto restore a deleted file, when it's not
>> known, when the file has been deleted.
>>
>> Suppose the following testcase:
>>
>> mkdir ~/backup /tmp/store
>> cd ~/backup
>> touch file1 file2
>> duplicity ~/backup file:///tmp/store
>> rm file1
>> duplicity ~/backup file:///tmp/store
>
> Thanks for the detail.
>
>> Now I'd like to restore file1, but I do NOT (want to) know, when
>> the file has been deleted. I'd like to get it back at its "latest
>> version", so to say.
>>
>> How would I do that?
>>
>> address@hidden ~ $ duplicity --file-to-restore file1
>> file:///tmp/sicherung file1
>
> I'm guessing this is a typo - you used /tmp/store above.
Yep, you're right. Stupid copy'n'paste error on my side.
>> GnuPG passphrase: Retype to confirm: file1 not found in archive, no
>> files restored.
>>
>> This did not work, as it seems.
>>
>> What's the correct way to do this?
>
> There is no way to say 'restore the latest' version of the file,
This sucks :(
> however, if one enters the command:
>
> $ duplicity -t 1D --file-to-restore file1 file:///tmp/store file1
>
> duplicity will correctly restore 'file1' from your example above.
Yep. But it'll restore it from the backup 1D before. There might
be more recent versions :(
> In
> the man page, under TIME FORMATS, there is a complete list of formats
> duplicity will accept. The '-t 1D' told duplicity to look at most one
> day back for file1. Leaving that out means to only look at the most
> recent backup.
Yep, understood. Thanks.
> To find out how far back to go may take a few tries. Go back a week, if
> the file exists, go forward 3 days, then forwards by 1 day increments
> until it does not exist. Do similarly for month/week/day increments.
Yikes...
Is it possible to get a list of all the backups that have been taken and
also get a list of all the files that have been part of this backup?
So, is it possible to get a listing of all the files that are part of
the backup taken 3D ago?
Thanks,
Alexander Skwar