Closed filippocarletti closed 5 years ago
Test case Check the bug is not reproducible
QA of nethserver-backup-data-1.5.1-1.2.gf64f105.ns7.noarch.rpm
mount a usb disk and do a backup on it
[root@ns7loc8 ~]# /sbin/e-smith/backup-data-wrapper backup-data
[root@ns7loc8 ~]# mount /dev/sdb /mnt/plop/
[root@ns7loc8 ~]# ll /mnt/plop/
total 4
drwxr-xr-x 2 root root 4096 Feb 28 16:36 ns7loc8
[root@ns7loc8 ~]# tree /mnt/plop/ns7loc8/
/mnt/plop/ns7loc8/
├── backup-config.tar.xz
├── duplicity-full.20190228T153651Z.manifest
├── duplicity-full.20190228T153651Z.vol1.difftar.gz
└── duplicity-full-signatures.20190228T153651Z.sigtar.gz
the backup is ok with an attached usb drive
then remove the usb drive, restart the server and start the backup again
[root@ns7loc8 ~]# /sbin/e-smith/backup-data-wrapper backup-data
[root@ns7loc8 ~]# ll /
total 20
lrwxrwxrwx 1 root root 7 Aug 18 2018 bin -> usr/bin
dr-xr-xr-x. 5 root root 4096 Feb 28 2019 boot
drwxr-xr-x 19 root root 3100 Feb 28 15:38 dev
drwxr-xr-x. 102 root root 8192 Feb 28 2019 etc
drwxr-xr-x. 2 root root 6 Dec 10 12:48 home
lrwxrwxrwx 1 root root 7 Aug 18 2018 lib -> usr/lib
lrwxrwxrwx 1 root root 9 Aug 18 2018 lib64 -> usr/lib64
drwxr-xr-x. 2 root root 6 Apr 11 2018 media
drwxr-xr-x. 4 root root 44 Feb 28 2019 mnt
drwxr-xr-x. 2 root root 6 Apr 11 2018 opt
dr-xr-xr-x 135 root root 0 Feb 28 2019 proc
dr-xr-x---. 4 root root 208 Apr 11 2018 root
drwxr-xr-x 31 root root 1060 Feb 28 15:38 run
lrwxrwxrwx 1 root root 8 Aug 18 2018 sbin -> usr/sbin
drwxr-xr-x. 2 root root 6 Apr 11 2018 srv
dr-xr-xr-x 13 root root 0 Feb 28 2019 sys
drwxrwxrwt. 9 root root 4096 Feb 28 15:38 tmp
drwxr-xr-x. 13 root root 155 Aug 18 2018 usr
drwxr-xr-x. 20 root root 278 Aug 18 2018 var
the backup is not done on /
[root@ns7loc8 ~]# cat /var/log/backup/backup-backup-data-201902281538.log
Backup: backup-data
Backup started at 2019-02-28 15:38:42
Pre backup scripts status: SUCCESS
Device for 8G not found at /etc/e-smith/events/actions/mount-usb line 60.
Can't mount /mnt/backup-backup-data
Action 'backup-data-duplicity backup-data': FAIL
Backup status: FAIL
and we have an error in backup log but not in /var/log/messages
set verified
I found that duplicity files where stored in the / filesystem instead of the usb disk.
Steps to reproduce
Expected behavior
Error: disk not present
Actual behavior
Succesful backup stored on /
Components
nethserver-backup-data-1.5.1-1.ns7.noarch