The old way, that is known to work well:
- Confirming that the software is working correctly - currently, it's a two-step process:
- Here we do a restore to a pipe, and without writing to disk, use GNU tar's --diff
option to compare what's coming out of backshift with what's on the system:
- ~/src/home-svn/backshift/trunk/backshift \
- --save-directory $(pwd) \
- --produce-tar \
- --backup-id 1307122264.51_benchbox_test_fri-jun--3-10-31-04-2011_8bb8b332b1b34ea4 | \
- (cd / && tar --diff)
- Note that the above will check all the files in the backup, against the same-named files in the filesystem. But it won't check for files
that should've
been in the backup, but weren't. For that though, a simple file count comparison works wonders; IOW, compare the output of the following two commands
(adjust for your backupid, of course). We restrict the file types on the find command, because it makes little sense to back up some file
types, EG unix domain sockets:
- backshift \
- --list-backup \
- --save-directory /VMs/save-directory \
- --backup-id 1311139063.01_benchbox_just-slash_tue-jul-19-22-17-43-2011_0852594c036d8720 2>&1 | \
- wc -l
- find / -xdev \( -type b -o -type c -o -type d -o -type p -o -type f -o -type l \) -print | wc -l
- Further note that --list-backup is much faster than --produce-tar, and that a simple file count goes a long way toward verifying that things are
working, so if you're in a hurry the second step alone might suffice.
The new way, that may still have some quirks:
- backshift-verify-filesystem \
- --backup-id 1542811179.60_zareason2_just-digital-assets_wed-nov-21-06-39-39-2018_2d3cee69438359b0 \
- --filesystem-directory /digital-assets \
- --save-directory /backshift-production/save-directory