Easy way to test if my duplicity backups are working?

Asked by Pope Rigby on 2020-06-06

I don't want to overwrite my entire filesystem with the backed up version, so I'm wondering if there's an easy way to check if it's working without doing that.

Question information

Language:
English Edit question
Status:
Solved
For:
Duplicity Edit question
Assignee:
No assignee Edit question
Solved by:
edso
Solved:
2020-06-07
Last query:
2020-06-07
Last reply:
2020-06-07

Hi,

Yes, look at the verify command. It's in the man page, but simply:

$ duplicity verify [options] [--compare-data] [--file-to-restore <relpath>]
[--time time] source_url target_directory

Verify without --compare-data will verify the consistency (hashes0 of the
backup. With --compare-data all of the target is compared to the source.
That takes a while longer.

...Ken

On Sat, Jun 6, 2020 at 6:15 PM Pope Rigby <
<email address hidden>> wrote:

> New question #691181 on Duplicity:
> https://answers.launchpad.net/duplicity/+question/691181
>
> I don't want to overwrite my entire filesystem with the backed up version,
> so I'm wondering if there's an easy way to check if it's working without
> doing that.
>
> --
> You received this question notification because your team duplicity-team
> is an answer contact for Duplicity.
>
> _______________________________________________
> Mailing list: https://launchpad.net/~duplicity-team
> Post to : <email address hidden>
> Unsubscribe : https://launchpad.net/~duplicity-team
> More help : https://help.launchpad.net/ListHelp
>

Pope Rigby (poperigby) said : #2

Ok that's useful, thanks. Can I specify a include/exclude list?

For backup, yes. For restore, planned. Nowhere else.

...Ken

On Sun, Jun 7, 2020 at 2:55 PM Pope Rigby <
<email address hidden>> wrote:

> Question #691181 on Duplicity changed:
> https://answers.launchpad.net/duplicity/+question/691181
>
> Pope Rigby posted a new comment:
> Ok that's useful, thanks. Can I specify a include/exclude list?
>
> --
> You received this question notification because your team duplicity-team
> is an answer contact for Duplicity.
>
> _______________________________________________
> Mailing list: https://launchpad.net/~duplicity-team
> Post to : <email address hidden>
> Unsubscribe : https://launchpad.net/~duplicity-team
> More help : https://help.launchpad.net/ListHelp
>

edso (ed.so) said : #4

On 07.06.2020 21:55, Pope Rigby wrote:
> Question #691181 on Duplicity changed:
> https://answers.launchpad.net/duplicity/+question/691181
>
> Pope Rigby posted a new comment:
> Ok that's useful, thanks. Can I specify a include/exclude list?
>

the man page[1] states

duplicity verify [options] [--compare-data] [--file-to-restore <relpath>] [--time time] source_url target_directory

that the parameter '--file-to-restore' is supported. hence it should limit verifying to the folder/file give there. if that in fact also limits the verification to those volumes said file/folder to restore is contained in when '--compare-data' is not given i don't know. but that should be easily tested by a simple trial and comparing the run times.
you may of course consult the source code as well ;)

..ede/duply.net

[1] http://duplicity.nongnu.org/vers8/duplicity.1.html

Pope Rigby (poperigby) said : #5

I was just going to let it do the entirety of root, but it seems to be stuck at:

Error accessing possibly locked file /run/user/1000/doc

Best edso (ed.so) said : #6

On 07.06.2020 22:15, Pope Rigby wrote:
> Question #691181 on Duplicity changed:
> https://answers.launchpad.net/duplicity/+question/691181
>
> Pope Rigby posted a new comment:
> I was just going to let it do the entirety of root, but it seems to be
> stuck at:
>
> Error accessing possibly locked file /run/user/1000/doc
>

not really in the scope of your question above ;)

anyway. '/run/' as well as '/proc/' or '/sys/' are special operating system mountpoints and not meant to be completely readable (even to root)! how about limiting your backup to folders known to hold important data like '/etc/' and '/home/'?

..ede/duply.net

Pope Rigby (poperigby) said : #7

Thanks edso, that solved my question.