Bug 1473640 - Restore with multiple ISOs does not detect additional ISOs due to blkid output parsing mismatch
Restore with multiple ISOs does not detect additional ISOs due to blkid outpu...
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: rear (Show other bugs)
7.3
All Linux
urgent Severity urgent
: rc
: ---
Assigned To: Jakub Mazanek
qe-baseos-daemons
: Patch
Depends On:
Blocks: 1420851
  Show dependency treegraph
 
Reported: 2017-07-21 07:15 EDT by Julio Entrena Perez
Modified: 2017-09-04 10:15 EDT (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2017-09-04 04:53:36 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Julio Entrena Perez 2017-07-21 07:15:23 EDT
Description of problem:
A backup that results in multiple ISO images due to ISO_MAX_SIZE= can not be restored.
After processing the first ISO, ReaR keeps prompting for the 2nd ISO image and is unable to recognise it.
Due to issue in bug 1462189 this means that there is no possible way of using the built-in backup method.

Version-Release number of selected component (if applicable):
rear-1.17.2-9.el7_3

How reproducible:
Always

Steps to Reproduce:
1. Configure the built-in backup method to limit the size of the output ISO images:

# cat /etc/rear/local.conf  | grep -v ^#
OUTPUT=ISO
OUTPUT_URL=file:///srv/backup
BACKUP=NETFS
BACKUP_URL=iso:///backup
ISO_MAX_SIZE=2048

2. Create rescue media with built-in backup ("rear mkbackup")

3. Boot with the first ISO image and wait for the prompt for the second ISO image.

4. Insert second ISO image.

Actual results:
ReaR keeps fails to detect and keeps prompting for additional ISO images.

Expected results:
ReaR detects additional ISO images and completes restore.

Additional info:
This is a known issue already fixed upstream: https://github.com/rear/rear/issues/1081

File /usr/share/rear/restore/NETFS/default/40_restore_backup.sh contains:

label=$(blkid /dev/${dev} | awk 'BEGIN{FS="[=\"]"} {print $3}')

But output of 'blkid' in the restore environment (once booted with the first ISO) is:

# blkid /dev/cdrom
/dev/cdrom: UUID="2017-07-19-11-10-00-00" LABEL="RELAXRECOVER_01" TYPE="iso9660"

So it's matching 2017-07-19-11-10-00-00 rather than RELAXRECOVER_01.

Full patch (combined with fix for issue https://github.com/rear/rear/pull/1082) is:

https://github.com/rear/rear/commit/938a2cf4302fca2b6fdff437669dd5c9fe36df53

The combination of this issue with genisoimage inability to create ISO images containing files larger than 4GB (see bug 1462189 ) results in the built-in backup method being completely broken, hence the severity.

Note You need to log in before you can comment on or make changes to this bug.