duplicity-talk
[Top][All Lists]
Advanced

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

Re: [Duplicity-talk] single file restore not working


From: Aaron
Subject: Re: [Duplicity-talk] single file restore not working
Date: Tue, 06 Dec 2016 09:33:12 +0000

Hi Chris,

 

On 2016-12-06 06:17, C.Enzmann via Duplicity-talk wrote:

I have a working backup, and directory restore works fine as well. But if I try to restore using
'duplicity restore -v8 --use-agent --ssh-options="-oIdentityFile=/dup/.ssh/id_duplicity" --name=`hostname` scp://address@hidden/BackUps/'
with any combination of "--file-to-restore system1/test.txt" and "/home/me/test_root", in any order and regardless of path settings (relative, absolute) I get either
"Restore destination directory /home/me/test_root already exists. Will not overwrite."
or at best
"Command line error: restore option incompatible with inc backup"
[...]
Please, I need your help to figure out what I'm doing wrong. [In addition, what is needed to restore / operate on multiple files, i.e. with wildcards?]

I am not in front of a duplicity installation, but the error suggests that you are trying to restore to /home/me/test_root but that that destination is not empty. Maybe try creating a new folder with nothing in it and using that as your target (i.e. add it to the end of your command above).

The order of arguments/options is important. If you want to do a restore then the backup location (i.e. "scp://address@hidden/BackUps/") should be before where you want to restore to (e.g. "/home/me/test_root"). I suspect your "Command line error: restore option incompatible with inc backup" is because you have structured your restore line in a way that duplicity thinks looks like a backup line. 

The format of --file-to-restore should be relative (as the file is printed by list-current-files). If you need to restore multiple files/wildcards, and you have enough space, your easiest option would be to restore the entire backup and then search that. I do not believe that there is any way to wildcard restore, so your only other option that springs to mind would be to parse the output of --list-current-files, identify the ones that you want and then feed them into --file-to-restore commands.

As a broader comment, you may like to have a look at duply (which is a wrapper around duplicity). If you have a lot of additional arguments (as you do) then it does a good job of simplifying the commands that you need to run to interact with your backups.

Kind regards,

Aaron



reply via email to

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