#1492 Issue closed
: Unable to determine raw USB device¶
Labels: support / question
, fixed / solved / done
loyeyoung opened issue at 2017-09-13 18:06:¶
BUG in /usr/share/rear/prep/USB/Linux-i386/350_check_usb_disk.sh
line
30:
'Unable to determine raw USB device for /dev/dm-8'
- rear version (/usr/sbin/rear -V):
#==============================================================
Relax-and-Recover 2.2 / 2017-07-20
# dnf info rear
Installed Packages
Name : rear
Version : 2.2
Release : 1.fc26
Arch : x86_64
Size : 1.3 M
Source : rear-2.2-1.fc26.src.rpm
Repo : @System
From repo : updates
- OS version (cat /etc/rear/os.conf or lsb_release -a):
#==============================================================
# lsb_release -a
LSB Version: :core-4.1-amd64:core-4.1-noarch:cxx-4.1-amd64:cxx-4.1-noarch:desktop-4.1-amd64:desktop-4.1-noarch:languages-4.1-amd64:languages-4.1-noarch:printing-4.1-amd64:printing-4.1-noarch
Distributor ID: Fedora
Description: Fedora release 26 (Twenty Six)
Release: 26
Codename: TwentySix
- rear configuration files (cat /etc/rear/site.conf or cat /etc/rear/local.conf):
#==============================================================
# for thing in $(ls /etc/rear/*.conf) ; do echo ============== ${thing} ============ ; cat ${thing} ; done
============== /etc/rear/local.conf ============
OUTPUT=USB
TMPDIR=/var/tmp
BACKUP=NETFS
BACKUP_URL=usb:///dev/disk/by-label/REAR-001
BACKUP_MOUNTCMD="mount -L REAR-001"
BACKUP_UMOUNTCMD="umount"
BACKUP_PROG=tar
BACKUP_PROG_ARCHIVE=backup
BACKUP_PROG_COMPRESS_OPTIONS=--use-compress-program="xz -9"
BACKUP_PROG_COMPRESS_SUFFIX=.xz
BACKUP_PROG_CRYPT_ENABLED=0
BACKUP_PROG_CRYPT_KEY=
BACKUP_PROG_CRYPT_OPTIONS=/usr/bin/openssl des3 -salt -k
BACKUP_PROG_DECRYPT_OPTIONS=/usr/bin/openssl des3 -d -k
BACKUP_PROG_EXCLUDE=( '/tmp/*' '/dev/shm/*' "$VAR_DIR/output/*" '/var/vm' )
BACKUP_PROG_OPTIONS=--anchored
BACKUP_PROG_OPTIONS_CREATE_ARCHIVE=
BACKUP_PROG_OPTIONS_RESTORE_ARCHIVE=
BACKUP_PROG_SUFFIX=.tar
BACKUP_PROG_WARN_PARTIAL_TRANSFER=1
============== /etc/rear/os.conf ============
OS_VENDOR=Fedora
OS_VERSION=26
============== /etc/rear/rescue-disk.conf ============
OUTPUT=ISO
OUTPUT_URL=file:///rear/
TMPDIR=/var/tmp
BACKUP=NETFS
BACKUP_URL=usb:///dev/disk/by-label/REAR-001
BACKUP_MOUNTCMD="mount -L REAR-001"
BACKUP_UMOUNTCMD="umount"
BACKUP_PROG=tar
BACKUP_PROG_ARCHIVE=backup
BACKUP_PROG_COMPRESS_OPTIONS=--use-compress-program="xz -9"
BACKUP_PROG_COMPRESS_SUFFIX=.xz
BACKUP_PROG_CRYPT_ENABLED=0
BACKUP_PROG_CRYPT_KEY=
BACKUP_PROG_CRYPT_OPTIONS=/usr/bin/openssl des3 -salt -k
BACKUP_PROG_DECRYPT_OPTIONS=/usr/bin/openssl des3 -d -k
BACKUP_PROG_EXCLUDE=( '/tmp/*' '/dev/shm/*' "$VAR_DIR/output/*" '/var/vm' )
BACKUP_PROG_OPTIONS=--anchored
BACKUP_PROG_OPTIONS_CREATE_ARCHIVE=
BACKUP_PROG_OPTIONS_RESTORE_ARCHIVE=
BACKUP_PROG_SUFFIX=.tar
BACKUP_PROG_WARN_PARTIAL_TRANSFER=1
============= END ====================
-
Are you using legacy BIOS or UEFI boot?
Legacy -
Brief description of the issue:
Relax-and-Recover fails when run from either of the following cron jobs:
#==============================================================
# Check for changes in file system and make a rescue disk if necessary
30 1 * * * /usr/bin/mount /dev/disk/by-label/REAR-000 ; /usr/sbin/rear checklayout || /usr/sbin/rear mkrescue ; /usr/bin/mv -f /var/lib/rear/output/rear-aquinas.iso /mnt/rear/ ; /usr/bin/umount /mnt/rear
# Make a full backup on Sunday during Mass
30 10 * * sun /usr/bin/mount /dev/disk/by-label/REAR-001 ; /usr/bin/rear -v mkbackup ; /usr/sbin/poweroff
Result: No backup created.
I am including details from daily cronjob (i.e., 30 1 * * *
).
Error message is:
#==============================================================
ERROR:
====================
BUG in /usr/share/rear/prep/USB/Linux-i386/350_check_usb_disk.sh line 30:
'Unable to determine raw USB device for /dev/dm-8'
--------------------
Please report this issue at https://github.com/rear/rear/issues
and include the relevant parts from /var/log/rear/rear-aquinas.log
preferably with full debug information via 'rear -d -D mkrescue'
====================
Aborting due to an error, check /var/log/rear/rear-aquinas.log for details
/usr/bin/bash: line 1: 15939 Terminated /usr/sbin/rear mkrescue
Device mapping:
/dev/disk/by-label/REAR-001 -> ../../dm-8
Error log at https://gist.github.com/loyeyoung/da9ec52fdb4fa07622f0ee173d0dcc4a. It was generated when trying to run cron job from command line, which had the same result.
- Work-around, if any:
Unknown
gozora commented at 2017-10-15 08:42:¶
I'm affraid REAR-001 is not a valid label to work with.
rear format
workflow, which is mandatory for USB backup, labels disk
REAR-000 which is hardcoded. I guess your problem originates here.
I can see you are trying to use to use ReaR in more advance way then usual. If you need to use multiple disks for backup, it could be helpful to check Using Multiple Backups for Relax-and-Recover
V.
jsmeix commented at 2017-10-16 10:18:¶
@gozora
many thanks that you spotted the 'REAR-001'.
I overlooked it and had no idea what went wrong...
@loyeyoung
the 'REAR-000' is hardcoded used at many places in the code, cf.
https://github.com/rear/rear/issues/1520#issuecomment-333142799
[Export of Github issue for rear/rear.]