bug-tar
[Top][All Lists]
Advanced

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

[Bug-tar] problem (bug?) using listed-incremental on multiple file-syste


From: Niels Laukens
Subject: [Bug-tar] problem (bug?) using listed-incremental on multiple file-systems
Date: Mon, 04 Oct 2004 13:20:29 +0200
User-agent: Mozilla Thunderbird 0.8 (X11/20040917)

Hi,

I'm having a problem restoring incremental backups. I think it's a bug, but it's also possible that I'm just not using th right commands.
Here is the situation:

Filesystem layout:
/ (reiserfs)
  /boot (ext2)
  /usr (reiserfs)
  /var (reiserfs)
  /tmp (reiserfs)
  /mnt/... (various, doesn't matter)

I create my backups like this: (listfile is non-existant)
tar --create --one-file-system --preserve-permissions --label "Bla" \
--exclude="/some/file" --listed-incremental "listfile" \
/boot /usr /var /tmp / | bzip2 ...

The second (incremental backup) is made with the same command, only here listfile is a copy of the one made by the first backup.


To restore, i use
tar jxvf tar-file.tar.bz2 --listed-incremental "listfile"
with listfile the listfile created with the level0 backup.

Next, I do the same, with the second (incremental) backup (with it's listfile). Here, however, tar deletes ALL directories on the paritions (i.e. rm -rf usr/* boot/* tmp/* var/*) and then recreates then (empty of course) and adds the changed files.

I guess the problem is that those "directories" are on different file systems. Can anyone confirm that this is a bug? or am I just not using the right commands?



A step-by-step guide to reproduce:
1. Go to an empty directory (optional, but recommended)
2. be root
3. execute these commands:
------SNIP-----
mkdir -p root/boot
dd if=/dev/zero of=boot bs=512 count=8192
mke2fs -F boot
mount -o loop boot root/boot
dd if=/dev/urandom of=root/1 bs=512 count=2048
dd if=/dev/urandom of=root/boot/2 bs=512 count=2048

sleep 10

tar cvpf 1.tar --one-file-system --listed-incremental 1.lst \
root/boot root

sleep 10

cp 1.lst 2.lst
tar cvpf 2.tar --one-file-system --listed-incremental 2.lst \
root/boot root

ls root/boot

umount root/boot
rm -rf root/ boot

tar xvf 1.tar --listed-incremental 1.lst
tar xvf 2.tar --listed-incremental 2.lst

ls root/boot
------SNIP-----
4. see that the boot partition is NOT restored correctly


Side info: I'm using tar 1.14




reply via email to

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