[Rear-users] stopping rear ends with empty usb disk

upen upendra.gandhi at gmail.com
Tue Jul 12 17:57:08 CEST 2011


Hello again,

I tried to reproduce this.

First I ran 'rear mkbackup' on NFS share using NETFS option. This was
done on Gentoo. It finished fine and created hostname folder in the
NFS share as below.

NFS-server#ls -al /home/nfs/mint/
total 12
drwxr-xr-x. 3 root root 4096 Jul 11 15:07 .
drwx------. 7 root root 4096 Jul  5 16:18 ..
drwxr-x---. 2 root root 4096 Jul 12 10:23 upendra_ots

Then I went to my RHEL6 box and ran 'rear mkbackup' as shown below,
and pressed CTRL C when 123MB was archived.

rear -v mkbackup
Relax & Recover Version 1.11.0 / 2011-05-24 10:39:25 +0200
The preparation phase  OK
Physical devices that will be recovered: /dev/sda
Saving disk partitions.
Saving LVM layout.
Saving Filesystem layout.
Saving Swap information.
Saving Encrypted volumes.
Creating root FS layout  OK
Copy files and directories  OK
Copy program files & libraries  OK
Copy kernel modules  OK
Checking udev  OK
Using kernel /boot/vmlinuz-2.6.32-131.0.15.el6.x86_64
Create initramfs  OK
Making ISO image  OK
Wrote ISO Image /tmp/rear-rhel6.iso (39M)
Copying resulting files to nfs location  OK
Creating tar archive
'/tmp/rear.8rodXYEjmhq40kR/netfs/rhel6.host.com/backup.tar.gz'
Archived 123 MiB [avg 4350 KiB/sec]  \^CFinished in 71 seconds.

Now it was time to see NFS share from NFS-server itself, so I ran ls
-al on NFS share. After some time the gentoo backup(upendra_ots)
directory vanished. You can see below,

[root at upensl ~]# ls -al /home/nfs/mint/
total 16
drwxr-xr-x. 4 root root 4096 Jul 12 10:40 .
drwx------. 7 root root 4096 Jul  5 16:18 ..
drwxr-x---. 2 root root 4096 Jul 12 10:40 rhel6.host.com
drwxr-x---. 2 root root 4096 Jul 12 10:23 upendra_ots
[root at upensl ~]# ls -al /home/nfs/mint/
total 16
drwxr-xr-x. 4 root root 4096 Jul 12 10:40 .
drwx------. 7 root root 4096 Jul  5 16:18 ..
drwxr-x---. 2 root root 4096 Jul 12 10:41 rhel6.host.com
drwxr-x---. 2 root root 4096 Jul 12 10:41 upendra_ots
[root at upensl ~]# ls -al /home/nfs/mint/
total 16
drwxr-xr-x. 4 root root 4096 Jul 12 10:40 .
drwx------. 7 root root 4096 Jul  5 16:18 ..
drwxr-x---. 2 root root 4096 Jul 12 10:41 rhel6.host.com
drwxr-x---. 2 root root 4096 Jul 12 10:41 upendra_ots
[root at upensl ~]# ls -al /home/nfs/mint/
total 12
drwxr-xr-x. 3 root root 4096 Jul 12 10:41 .
drwx------. 7 root root 4096 Jul  5 16:18 ..
drwxr-x---. 2 root root 4096 Jul 12 10:41 rhel6.host.com

What remains is rhel6 backup which really isn't helpful at all as it
was not complete.

Good thing when I did ps -ef | grep rear, no rear process was running
so it killed everything also unmounted /tmp/rear.xxx/netfs on its own.

Now I tried to ran rear mkbackup from gentoo and same thing happened
when I pressed CTRL-C , it deleted the existing rhel6 directory.

Now , weired thing because it is gentoo :), ps -ef | grep rear showed
me below processes,
 ps -ef | grep rear
root     20951     1  3 10:43 pts/47   00:00:02 /bin/bash
/usr/sbin/rear -v mkbackup
root     30315     1  2 10:43 pts/47   00:00:00 tar --sparse
--block-number --totals --verbose --no-wildcards-match-slash
--one-file-system --ignore-failed-read --gzip -X
/tmp/rear.uwp7Fm5m4EeZHvr/backup-exclude.txt -C / -c -f
/tmp/rear.uwp7Fm5m4EeZHvr/netfs/upendra_ots/backup.tar.gz / /nfs /nfs1
/boot /tmp/rear-upendra_ots.log


df -kh
NFS-server:/home/nfs/mint
                      147G  106G   34G  76% /tmp/rear.uwp7Fm5m4EeZHvr/netfs



Log file on Gentoo related to second mkbackup command.
....
2011-07-12 10:43:35 Creating tar archive
'/tmp/rear.uwp7Fm5m4EeZHvr/netfs/upendra_ots/backup.tar.gz'
tar: Removing leading `/' from member names
2011-07-12 10:43:42 Running exit tasks.
2011-07-12 10:43:42 The following jobs are still active:
[1]+ 30310 Running                 ( case "$BACKUP_PROG" in
    tar)
        $BACKUP_PROG --sparse --block-number --totals --verbose
--no-wildcards-match-slash --one-file-system --ignore-failed-read
$BACKUP_PROG_OPTIONS ${BACKUP_PROG_BLOCKS:+-b $BACKUP_PROG_BLOCKS}
$BACKUP_PROG_COMPRESS_OPTIONS -X $BUILD_DIR/backup-exclude.txt -C / -c
-f "$backuparchive" $(cat $BUILD_DIR/backup-include.txt) $LOGFILE
    ;;
    rsync)
        mkdir -vp "$backuparchive" 1>&2; $BACKUP_PROG --sparse
--archive --hard-links --one-file-system --verbose --delete
--numeric-ids --exclude-from=$BUILD_DIR/backup-exclude.txt
--delete-excluded $(cat $BUILD_DIR/backup-include.txt)
"$backuparchive"
    ;;
    *)
        Log "Using unsupported backup program '$BACKUP_PROG'";
$BACKUP_PROG $BACKUP_PROG_COMPRESS_OPTIONS
$BACKUP_PROG_OPTIONS_CREATE_ARCHIVE $BUILD_DIR/backup-exclude.txt
$BACKUP_PROG_OPTIONS $backuparchive $(cat
$BUILD_DIR/backup-include.txt) $LOGFILE > $backuparchive
    ;;
esac > "${BUILD_DIR}/${BACKUP_PROG_ARCHIVE}.log" ) &
/usr/share/rear/lib/_input-output-functions.sh: line 57: 30310 Killed
                ( case "$BACKUP_PROG" in
    tar)
        $BACKUP_PROG --sparse --block-number --totals --verbose
--no-wildcards-match-slash --one-file-system --ignore-failed-read
$BACKUP_PROG_OPTIONS ${BACKUP_PROG_BLOCKS:+-b $BACKUP_PROG_BLOCKS}
$BACKUP_PROG_COMPRESS_OPTIONS -X $BUILD_DIR/backup-exclude.txt -C / -c
-f "$backuparchive" $(cat $BUILD_DIR/backup-include.txt) $LOGFILE
    ;;
    rsync)
        mkdir -vp "$backuparchive" 1>&2; $BACKUP_PROG --sparse
--archive --hard-links --one-file-system --verbose --delete
--numeric-ids --exclude-from=$BUILD_DIR/backup-exclude.txt
--delete-excluded $(cat $BUILD_DIR/backup-include.txt)
"$backuparchive"
    ;;
    *)
        Log "Using unsupported backup program '$BACKUP_PROG'";
$BACKUP_PROG $BACKUP_PROG_COMPRESS_OPTIONS
$BACKUP_PROG_OPTIONS_CREATE_ARCHIVE $BUILD_DIR/backup-exclude.txt
$BACKUP_PROG_OPTIONS $backuparchive $(cat
$BUILD_DIR/backup-include.txt) $LOGFILE > $backuparchive
    ;;
esac > "${BUILD_DIR}/${BACKUP_PROG_ARCHIVE}.log" )
umount2: Device or resource busy
umount.nfs: /tmp/rear.uwp7Fm5m4EeZHvr/netfs: device is busy
umount2: Device or resource busy
umount.nfs: /tmp/rear.uwp7Fm5m4EeZHvr/netfs: device is busy
2011-07-12 10:43:43 Finished in 43 seconds.
2011-07-12 10:43:43 Removing build area /tmp/rear.uwp7Fm5m4EeZHvr
rm: cannot remove `/tmp/rear.uwp7Fm5m4EeZHvr/netfs/upendra_ots':
Directory not empty
2011-07-12 10:43:50 End of program reached

Thanks,
Upen




More information about the rear-users mailing list