Bug 2117937
| Summary: | rear recover failing | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 9 | Reporter: | eric_hagen <eric.p.hagen.ctr> |
| Component: | rear | Assignee: | Pavel Cahyna <pcahyna> |
| Status: | CLOSED ERRATA | QA Contact: | David Jež <djez> |
| Severity: | medium | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 9.0 | CC: | djez, lzaoral, pcahyna |
| Target Milestone: | rc | Keywords: | Triaged |
| Target Release: | --- | Flags: | pm-rhel:
mirror+
|
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | rear-2.6-15.el9 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2022-11-15 10:42:27 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | 2119473, 2121237 | ||
| Bug Blocks: | |||
|
Description
eric_hagen
2022-08-12 18:46:39 UTC
Thank you for the detailed report. "lvm pvcreate" segfaults, can you please collect a core dump? You need to set this before running the problematic command: sysctl -w kernel.core_pattern=core.%e.%p because by default core dumps are not saved. I suspect that the segfault is related to the message WARNING: adding device /dev/sda3 with PVID Idoq6T48KrrrHBA2vhiNUp7g6Vq1XCTr which is already used for missing device. I have not seen this with successful restores. This is a bug in lvm2 unrelated to ReaR itself. Reproducer: 1. Get an empty disk (e.g. /dev/vdb). 2. Install lvm2 package. 2. Create one partition on /dev/vdb (e.g. using fdisk). 3. # pvcreate /dev/vdb1 4. # pvscan -u PV /dev/vdb1 with UUID LQbrRY-PusD-1f3b-bW0U-akcG-wEwy-s2DqBA lvm2 [<10.00 GiB] Total: 1 [<10.00 GiB] / in use: 0 [0 ] / in no VG: 1 [<10.00 GiB] 5. # wipefs -fa /dev/vdb1 6. # lvm pvcreate -ff --yes -v --uuid LQbrRY-PusD-1f3b-bW0U-akcG-wEwy-s2DqBA --norestorefile /dev/vdb1 Devices file PVID LQbrRYPusD1f3bbW0UakcGwEwys2DqBA not found on device /dev/vdb1. Wiping signatures on new PV /dev/vdb1. WARNING: adding device /dev/vdb1 with PVID LQbrRYPusD1f3bbW0UakcGwEwys2DqBA which is already used for missing device. Segmentation fault (core dumped) Coredump stack trace: #0 0x00007f65a449f8e2 __strcmp_evex (libc.so.6 + 0xcd8e2) #1 0x000055e3471c76ec device_id_add (lvm + 0xb96ec) #2 0x000055e3471914fa pvcreate_each_device (lvm + 0x834fa) #3 0x000055e34717715d pvcreate (lvm + 0x6915d) #4 0x000055e34716a935 lvm_run_command (lvm + 0x5c935) #5 0x000055e34716c561 lvm2_main (lvm + 0x5e561) #6 0x00007f65a4411eb0 __libc_start_call_main (libc.so.6 + 0x3feb0) #7 0x00007f65a4411f60 __libc_start_main@@GLIBC_2.34 (libc.so.6 + 0x3ff60) #8 0x000055e347146e45 _start (lvm + 0x38e45) ELF object binary architecture: AMD x86-64 Please try to recover again after moving /etc/lvm/devices in the rescue system away: mv /etc/lvm/devices /etc/lvm/devices.orig. For new backups, I would recommend omitting the directory from the rescue system entirely, which should revert LVM tools to the previous behavior: add COPY_AS_IS_EXCLUDE+=( /etc/lvm/devices ) to /etc/rear/local.conf. Confirmed work around for restore worked by moving /etc/lvm/devices. Confirmed work around for backup / restore addtion to /etc/rear/local.conf of: COPY_AS_IS_EXCLUDE+=( /etc/lvm/devices ) Restore completed without crashing. Thank you very much for your work on this. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (rear bug fix and enhancement update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2022:8246 |