Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1354656 - raid0 resync attempt segfaults
Summary: raid0 resync attempt segfaults
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: lvm2
Version: 7.3
Hardware: x86_64
OS: Linux
Target Milestone: rc
: ---
Assignee: Heinz Mauelshagen
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2016-07-11 21:21 UTC by Corey Marthaler
Modified: 2016-11-04 04:15 UTC (History)
8 users (show)

Fixed In Version: lvm2-2.02.161-1.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2016-11-04 04:15:42 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1445 normal SHIPPED_LIVE lvm2 bug fix and enhancement update 2016-11-03 13:46:41 UTC

Description Corey Marthaler 2016-07-11 21:21:48 UTC
Description of problem:
[root@host-084 ~]# lvs -a -o +devices
  LV                              VG            Attr       LSize   Pool Origin Data%  Meta%  Move Log Cpy%Sync Convert Devices                                                          
  rolist_during_resync            raid_sanity   rwi---r---   6.00g                                                     rolist_during_resync_rimage_0(0),rolist_during_resync_rimage_1(0)
  [rolist_during_resync_rimage_0] raid_sanity   Iwi---r---   3.00g                                                     /dev/sda1(0)                                                     
  [rolist_during_resync_rimage_1] raid_sanity   Iwi---r---   3.00g                                                     /dev/sda2(0)                                                     

[root@host-084 ~]# lvchange --resync -y raid_sanity/rolist_during_resync
Segmentation fault (core dumped)

Jul 11 16:15:17 host-084 kernel: lvchange[26311]: segfault at 50 ip 00007fe83605584f sp 00007ffd63f6ef90 error 4 in lvm[7fe83602c000+193000]

Core was generated by `lvchange --resync -y raid_sanity/rolist_during_resync'.
Program terminated with signal 11, Segmentation fault.
#0  0x00007fa879a4284f in _lvchange_resync (cmd=cmd@entry=0x7fa87b2a0020, lv=lv@entry=0x7fa87b35f010) at lvchange.c:449
449                     if (!activate_lv_excl_local(cmd, lvl->lv)) {
Missing separate debuginfos, use: debuginfo-install bzip2-libs-1.0.6-13.el7.x86_64 elfutils-libelf-0.163-3.el7.x86_64 elfutils-libs-0.163-3.el7.x86_64 glibc-2.17-105.el7.x86_64 libattr-2.4.46-12.el7.x86_64 libblkid-2.23.2-26.el7.x86_64 libcap-2.22-8.el7.x86_64 libgcc-4.8.5-4.el7.x86_64 libselinux-2.2.2-6.el7.x86_64 libsepol-2.1.9-3.el7.x86_64 libuuid-2.23.2-26.el7.x86_64 ncurses-libs-5.9-13.20130511.el7.x86_64 pcre-8.32-15.el7.x86_64 readline-6.2-9.el7.x86_64 systemd-libs-219-21.el7.x86_64 xz-libs-5.1.2-12alpha.el7.x86_64 zlib-1.2.7-15.el7.x86_64
(gdb) bt
#0  0x00007fa879a4284f in _lvchange_resync (cmd=cmd@entry=0x7fa87b2a0020, lv=lv@entry=0x7fa87b35f010) at lvchange.c:449
#1  0x00007fa879a45738 in _lvchange_single (cmd=cmd@entry=0x7fa87b2a0020, lv=<optimized out>, handle=handle@entry=0x7fa87b2e9a40) at lvchange.c:1179
#2  0x00007fa879a74336 in process_each_lv_in_vg (cmd=cmd@entry=0x7fa87b2a0020, vg=vg@entry=0x7fa87b35ded0, arg_lvnames=arg_lvnames@entry=0x7ffe0c634cd0, tags_in=tags_in@entry=0x7ffe0c634c80, stop_on_error=stop_on_error@entry=0, 
    handle=handle@entry=0x7fa87b2e9a40, process_single_lv=process_single_lv@entry=0x7fa879a43dd0 <_lvchange_single>) at toollib.c:2502
#3  0x00007fa879a75639 in _process_lv_vgnameid_list (process_single_lv=0x7fa879a43dd0 <_lvchange_single>, handle=0x7fa87b2e9a40, arg_tags=0x7ffe0c634c80, arg_lvnames=0x7ffe0c634ca0, arg_vgnames=0x7ffe0c634c90, vgnameids_to_process=0x7ffe0c634cc0, 
    read_flags=1048576, cmd=0x7fa87b2a0020) at toollib.c:2827
#4  process_each_lv (cmd=cmd@entry=0x7fa87b2a0020, argc=argc@entry=1, argv=argv@entry=0x7ffe0c635170, one_vgname=one_vgname@entry=0x0, one_lvname=one_lvname@entry=0x0, read_flags=read_flags@entry=1048576, handle=0x7fa87b2e9a40, handle@entry=0x0, 
    process_single_lv=process_single_lv@entry=0x7fa879a43dd0 <_lvchange_single>) at toollib.c:2973
#5  0x00007fa879a468c3 in lvchange (cmd=0x7fa87b2a0020, argc=1, argv=0x7ffe0c635170) at lvchange.c:1336
#6  0x00007fa879a5e8e9 in lvm_run_command (cmd=cmd@entry=0x7fa87b2a0020, argc=1, argc@entry=4, argv=0x7ffe0c635170, argv@entry=0x7ffe0c635158) at lvmcmdline.c:1715
#7  0x00007fa879a5f490 in lvm2_main (argc=4, argv=0x7ffe0c635158) at lvmcmdline.c:2184
#8  0x00007fa87875bb15 in __libc_start_main () from /lib64/
#9  0x00007fa879a42f91 in _start ()

Version-Release number of selected component (if applicable):

lvm2-2.02.160-1.el7    BUILT: Wed Jul  6 11:16:47 CDT 2016
lvm2-libs-2.02.160-1.el7    BUILT: Wed Jul  6 11:16:47 CDT 2016
lvm2-cluster-2.02.160-1.el7    BUILT: Wed Jul  6 11:16:47 CDT 2016
device-mapper-1.02.130-1.el7    BUILT: Wed Jul  6 11:16:47 CDT 2016
device-mapper-libs-1.02.130-1.el7    BUILT: Wed Jul  6 11:16:47 CDT 2016
device-mapper-event-1.02.130-1.el7    BUILT: Wed Jul  6 11:16:47 CDT 2016
device-mapper-event-libs-1.02.130-1.el7    BUILT: Wed Jul  6 11:16:47 CDT 2016
device-mapper-persistent-data-0.6.2-0.1.rc8.el7    BUILT: Wed Dec 31 18:00:01 CST 1969

Comment 2 Heinz Mauelshagen 2016-07-12 15:22:01 UTC
Check for raid0/raid0_meta LVs and reject the resync attempt.
Once on it, prohibit "lvchange --syncaction ..." for those LVs as well.

Comment 5 Corey Marthaler 2016-07-20 21:22:16 UTC
Fix verified in the latest rpms.

lvm2-2.02.161-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
lvm2-libs-2.02.161-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
lvm2-cluster-2.02.161-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
device-mapper-1.02.131-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
device-mapper-libs-1.02.131-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
device-mapper-event-1.02.131-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
device-mapper-event-libs-1.02.131-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
device-mapper-persistent-data-0.6.2-1.el7    BUILT: Mon Jul 11 04:32:34 CDT 2016
cmirror-2.02.161-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016
sanlock-3.4.0-1.el7    BUILT: Fri Jun 10 11:41:03 CDT 2016
sanlock-lib-3.4.0-1.el7    BUILT: Fri Jun 10 11:41:03 CDT 2016
lvm2-lockd-2.02.161-2.el7    BUILT: Wed Jul 20 07:48:14 CDT 2016

[root@host-082 ~]# lvs -a -o +devices
  LV                              VG          Attr       LSize Devices
  rolist_during_resync            raid_sanity rwi-a-r--- 6.00g rolist_during_resync_rimage_0(0),rolist_during_resync_rimage_1(0)
  [rolist_during_resync_rimage_0] raid_sanity iwi-aor--- 3.00g /dev/sda2(0)
  [rolist_during_resync_rimage_1] raid_sanity iwi-aor--- 3.00g /dev/sdc1(0)

[root@host-082 ~]# lvchange --resync -y raid_sanity/rolist_during_resync
  Unable to resync raid_sanity/rolist_during_resync.  It is not RAID4/5/6/10 or mirrored.

Comment 7 errata-xmlrpc 2016-11-04 04:15:42 UTC
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, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

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