|
From: | enric |
Subject: | RE: [Bug-tar] Possible Bug? |
Date: | Sat, 26 Jul 2008 22:28:42 +0200 |
Helmut, Thank you very much for your message! Probably you're right and tar tries to remove the directory instead of
renaming it. Anyway, before posting I already tried with "--recursive-unlink"
option but neither worked. The problem was the same since tar could not unlink directories
that are not empty. It seems to me very natural to rename directories keeping their content
unaltered (when reorganizing folders, for instance) and I would expect tar's incremental
backups to manage this use case properly so I guess I'm missing something
obvious here. Any suggestion? Thanks and regards!! Enric Hernández -----Mensaje original----- "Enric Hernandez"
<address@hidden> writes: >I'm using GNU tar version 1.20
for executing incremental backups. > >I don't dare to flag it as a
bug but I'm a little bit confused with the >following use case so that any
help will be very appreciated. > >I have the following hierarchy: > >dir_1 > dir_1_1 > file_1_1.txt > > >First, I perform a backup: > >tar -cpvzf tarfile -g snapshot_1 > >then I change the name of
directory "dir_1" to "dir_1_new", and I perform a >new incremental backup. > >The problem appears when
restoring. The first backup is restored ok, but >when restoring the second, tar
cannot rename the directory "dir_1" because >it's not empty. Does tar really try to rename
"dir_1" to "dir_1_new".
I think, renaming "dir_1" to
"dir_1_new" should be possible, as long as "dir_1" and "dir_1/.." are writable
and "dir_1/.." has not set the sticky bit. I guess, tar tries to remove
"dir_1", which fails, because it's not empty. >And if so, is there any way to
"force" tar to rename also not empty >directories
(some tar option or whatever)? There is a dangerous option:
'--recursive-unlink'. But read the
manual. -- Wer mir E-Mail schreiben will,
stelle | When writing me e-mail, please bitte vor meine
E-Mail-Adresse meinen | precede my e-mail address with Vor- und Nachnamen, etwa so: |
my full name, like Helmut Waitzmann
<address@hidden>, (Helmut Waitzmann) address@hidden |
[Prev in Thread] | Current Thread | [Next in Thread] |