Bug 2150348
| Summary: | lvm display cmds all segfault with sys_serial idtype devices present: "Checking 1 PVs with suspect serial numbers" | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 9 | Reporter: | Corey Marthaler <cmarthal> |
| Component: | lvm2 | Assignee: | LVM and device-mapper development team <lvm-team> |
| lvm2 sub component: | Devices, Filtering and Stacking | QA Contact: | cluster-qe <cluster-qe> |
| Status: | CLOSED ERRATA | Docs Contact: | |
| Severity: | medium | ||
| Priority: | unspecified | CC: | agk, heinzm, jbrassow, mcsontos, msnitzer, prajnoha, teigland, zkabelac |
| Version: | 9.2 | Keywords: | Triaged |
| Target Milestone: | rc | Flags: | pm-rhel:
mirror+
|
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | lvm2-2.03.17-3.el9 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2023-05-09 08:23:51 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: | |||
|
Description
Corey Marthaler
2022-12-02 15:46:40 UTC
This is in the latest -2 9.2 build as well. kernel-5.14.0-201.kpq1.el9 BUILT: Wed Nov 23 07:13:08 AM CST 2022 lvm2-2.03.17-2.el9 BUILT: Wed Nov 30 02:56:30 AM CST 2022 lvm2-libs-2.03.17-2.el9 BUILT: Wed Nov 30 02:56:30 AM CST 2022 Core was generated by `pvscan'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x000055f4c82e9a50 in memcpy (__len=<optimized out>, __src=<optimized out>, __dest=<optimized out>) at ../base/data-struct/list.c:36
36 assert(head->n);
(gdb) bt
#0 0x000055f4c82e9a50 in memcpy (__len=<optimized out>, __src=<optimized out>, __dest=<optimized out>) at ../base/data-struct/list.c:36
#1 device_ids_check_serial (cmd=0x55f4c9935a30, scan_devs=0x7ffc93747070, update_needed=0x0, noupdate=0) at ../lib/device/device_id.c:2579
#2 0x000055f4c82ca88c in lvmcache_label_scan (cmd=0x55f4c9935a30) at ../lib/cache/lvmcache.c:1626
#3 0x000055f4c82ac4f1 in process_each_pv (cmd=0x55f4c9935a30, argc=<optimized out>, argv=<optimized out>, only_this_vgname=<optimized out>,
all_is_set=<optimized out>, read_flags=<optimized out>, handle=<optimized out>, process_single_pv=<optimized out>)
at /usr/src/debug/lvm2-2.03.17-2.el9.x86_64/tools/toollib.c:4619
#4 0x000055f4c8297692 in pvscan_display_cmd (cmd=0x55f4c9935a30, argc=0, argv=0x7ffc93747b90) at /usr/src/debug/lvm2-2.03.17-2.el9.x86_64/tools/pvscan.c:162
#5 0x000055f4c8289cbf in lvm_run_command (cmd=<optimized out>, argc=<optimized out>, argv=<optimized out>)
at /usr/src/debug/lvm2-2.03.17-2.el9.x86_64/tools/lvmcmdline.c:3314
#6 0x000055f4c828bb31 in lvm2_main (argc=1, argv=0x7ffc93747b88) at /usr/src/debug/lvm2-2.03.17-2.el9.x86_64/tools/lvmcmdline.c:3847
#7 0x00007fdc95c3feb0 in __libc_start_call_main (main=main@entry=0x55f4c8265e30 <main>, argc=argc@entry=1, argv=argv@entry=0x7ffc93747b88)
at ../sysdeps/nptl/libc_start_call_main.h:58
#8 0x00007fdc95c3ff60 in __libc_start_main_impl (main=0x55f4c8265e30 <main>, argc=1, argv=0x7ffc93747b88, init=<optimized out>, fini=<optimized out>,
rtld_fini=<optimized out>, stack_end=0x7ffc93747b78) at ../csu/libc-start.c:389
#9 0x000055f4c8265f05 in _start ()
fix in main https://sourceware.org/git/?p=lvm2.git;a=commit;h=6613a61d3b5ce4d12a6fef79195eac34f30ef4da Non-PV devices (which have no PVID) were not being excluded from the serial number verification, which is based on using PVIDs. Fix verified in the latest build. Marking Verified:Tested. kernel-5.14.0-205.el9 BUILT: Fri Dec 2 07:14:37 AM CST 2022 lvm2-2.03.17-3.el9 BUILT: Wed Dec 7 10:41:40 AM CST 2022 lvm2-libs-2.03.17-3.el9 BUILT: Wed Dec 7 10:41:40 AM CST 2022 SCENARIO - attempt_all_valid_deviceidtypes: Test basic devicesfile addition using all known deviceidtypes (1974337|2136906) Available idtypes to attempt: ['sys_wwid', 'devname', 'sys_serial'] [...] adding entry to the devices file for /dev/sdg1 removing entry from the devices file for /dev/sdg1 Add devices file entry with overriden type **sys_serial** for /dev/sdg1 lvmdevices --deviceidtype sys_serial --adddev /dev/sdg1 Grabbing serial name from /sys/dev/block/.../evice/vpd_pg80 major=8 minor=96 sysfs idname: 00e969781f062abd22001e0d65604609 devicesfile idname: 00e969781f062abd22001e0d65604609 [root@hayes-03 ~]# cat /etc/lvm/devices/system.devices # LVM uses devices listed in this file. # Created by LVM command lvmdevices pid 2977 at Thu Dec 8 12:38:42 2022 VERSION=1.1.499 IDTYPE=sys_serial IDNAME=0083c91d2209183c2300e1d883604609 DEVNAME=/dev/sdg1 PVID=. PART=1 [root@hayes-03 ~]# pvs [root@hayes-03 ~]# vgs [root@hayes-03 ~]# lvs 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 (lvm2 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-2023:2544 |