[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Problems restoring hard-linked files
I tried to restore a file recently, but it failed, as it turned out that it
was hardlinked to another file. To retrieve it, I had to know which file it
was linked to, and restore that too.
The 'root' file isn't even necesarily the first alphabetically - just the one
tarsnap backs up first.
Is this a known issue? If it's difficult to get tarsnap to restore the file
automatically, I'd at least expect a more informative error message like
"Unable to restore hard linked file, unless you also restore file xxxxx",
or similar.
A transcript demonstrating this follows.
Cheers!
Jamie
| 23:05 (1) "/tmp" root@lapcat# tarsnap -xvf lapcat.20150808.0622.tar bin/tcsh
| x bin/tcsh: Can't create 'bin/tcsh'
| tarsnap: Error exit delayed from previous errors.
|
| *1* 23:08 (2) "/tmp" root@lapcat# l -i bin
| total 4
| 5 0 drwxr-xr-x 2 root wheel - 0 16 Aug 23:06 ./
| 2 4 drwxrwxrwt 3 root wheel - 192 16 Aug 23:06 ../
|
| 23:09 (3) "/tmp" root@lapcat# xzcat /var/log/tarsnap/verbose-log.20150808.0622.xz | grep 'bin/.*csh'
| -r-xr-xr-x 0 root wheel 382360 Jul 13 01:11 bin/csh
| hr-xr-xr-x 0 root wheel 0 Jul 13 01:11 bin/tcsh link to bin/csh
| -r-xr-xr-x 0 root wheel 378952 Oct 2 2014 bin/tcsh-my-patch
|
| 23:09 (4) "/tmp" root@lapcat# tarsnap -xvf lapcat.20150808.0622.tar bin/csh
| x bin/csh
|
| 23:10 (5) "/tmp" root@lapcat# l -i bin
| total 384
| 5 4 drwxr-xr-x 2 root wheel - 64 16 Aug 23:09 ./
| 2 4 drwxrwxrwt 3 root wheel - 192 16 Aug 23:06 ../
| 6 376 -r-xr-xr-x 1 root wheel - 382360 13 Jul 01:11 csh
|
| 23:10 (6) "/tmp" root@lapcat# tarsnap -xvf lapcat.20150808.0622.tar bin/tcsh
| x bin/tcsh
|
| 23:11 (7) "/tmp" root@lapcat# l -i bin
| total 760
| 5 4 drwxr-xr-x 2 root wheel - 128 16 Aug 23:11 ./
| 2 4 drwxrwxrwt 3 root wheel - 192 16 Aug 23:06 ../
| 6 376 -r-xr-xr-x 2 root wheel - 382360 13 Jul 01:11 csh
| 6 376 -r-xr-xr-x 2 root wheel - 382360 13 Jul 01:11 tcsh
|
| 23:11 (8) "/tmp" root@lapcat# rm -r bin
|
| 23:11 (9) "/tmp" root@lapcat# tarsnap -xvf lapcat.20150808.0622.tar bin/tcsh bin/csh
| x bin/csh
| x bin/tcsh
|
| 23:12 (10) "/tmp" root@lapcat# l -i bin
| total 760
| 5 4 drwxr-xr-x 2 root wheel - 128 16 Aug 23:12 ./
| 2 4 drwxrwxrwt 3 root wheel - 192 16 Aug 23:11 ../
| 6 376 -r-xr-xr-x 2 root wheel - 382360 13 Jul 01:11 csh
| 6 376 -r-xr-xr-x 2 root wheel - 382360 13 Jul 01:11 tcsh
|
| 23:13 (11) "/tmp" root@lapcat# xzcat /var/log/tarsnap/backup.20150808.0622.xz | grep '+ tarsnap'
| 06:22:03 | + tarsnap --one-file-system --nodump --disk-pause 5 --check-links --print-stats --humanize-numbers --checkpoint-bytes=536870912 --exclude /var/db/tarsnap/ --exclude /.snap/ --exclude /var/.snap/ --exclude /usr/.snap/ --exclude /test/.snap/ -cvf lapcat.20150808.0622.tar /usr/users/jamie/ /usr/src/sys/amd64/conf/ /var/ /usr/me/ / /usr/local/arpwatch/ /usr/local/etc/ /usr/local/openssl/ /usr/local/ossec-hids/ /usr/local/var/