Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1143747

Summary: attempting to set a persistent minor number on an exclusively activated thin volume causes locking/activation issues
Product: Red Hat Enterprise Linux 6 Reporter: Corey Marthaler <cmarthal>
Component: lvm2Assignee: Zdenek Kabelac <zkabelac>
lvm2 sub component: Clustering / clvmd (RHEL6) QA Contact: cluster-qe <cluster-qe>
Status: CLOSED ERRATA Docs Contact:
Severity: medium    
Priority: unspecified CC: agk, heinzm, jbrassow, msnitzer, prajnoha, prockai, zkabelac
Version: 6.6   
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: lvm2-2.02.118-1.el6 Doc Type: Bug Fix
Doc Text:
lvm2 tool used to accept options to set major:minor values for thin-pool volumes in some command variant. However such settings were later actually ignored. The fix has removed possibility to set major:minor for internal abstract volumes (which thin-pool actually is). Tool now correctly reports unsupported error message.
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-07-22 07:35:34 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:
Attachments:
Description Flags
-vvvv of the lvchange none

Description Corey Marthaler 2014-09-17 21:22:28 UTC
Description of problem:
[root@grant-01 ~]# vgcreate VG /dev/mapper/mpath[abcdefgh]p*
  Clustered volume group "VG" successfully created

[root@grant-01 ~]# lvcreate --activate ey --thinpool pool -L 1G VG
  Logical volume "lvol0" created
  Logical volume "pool" created

[root@grant-01 ~]# lvs -a -o +devices
  LV              VG  Attr       LSize  Pool Data% Meta% Devices
  [lvol0_pmspare] VG  ewi-------  4.00m                  /dev/mapper/mpathap1(0)
  pool            VG  twi-a-tz--  1.00g      0.00  0.98  pool_tdata(0)
  [pool_tdata]    VG  Twi-ao----  1.00g                  /dev/mapper/mpathap1(1)
  [pool_tmeta]    VG  ewi-ao----  4.00m                  /dev/mapper/mpathhp2(0)
[root@grant-02 ~]# lvs -a -o +devices
  LV              VG  Attr       LSize  Pool Data% Meta% Devices                
  [lvol0_pmspare] VG  ewi-------  4.00m                  /dev/mapper/mpathap1(0)
  pool            VG  twi---tz--  1.00g                  pool_tdata(0)
  [pool_tdata]    VG  Twi-------  1.00g                  /dev/mapper/mpathap1(1)
  [pool_tmeta]    VG  ewi-------  4.00m                  /dev/mapper/mpathfp2(0)
[root@grant-03 ~]# lvs -a -o +devices
  LV              VG  Attr       LSize  Pool Data% Meta% Devices                
  [lvol0_pmspare] VG  ewi-------  4.00m                  /dev/mapper/mpathhp1(0)
  pool            VG  twi---tz--  1.00g                  pool_tdata(0)
  [pool_tdata]    VG  Twi-------  1.00g                  /dev/mapper/mpathhp1(1)
  [pool_tmeta]    VG  ewi-------  4.00m                  /dev/mapper/mpathcp2(0)

# The following command works if the VG or LV is deactivated before this, however if it's not...

[root@grant-01 ~]# lvchange -aye -f -My --major 255 --minor 159 /dev/VG/pool
  Logical volume "pool" changed.
  Error locking on node grant-01: Device or resource busy

# Now the volume is "active" on all nodes in the cluster:

[root@grant-01 ~]# lvs -a -o +devices
  LV              VG  Attr       LSize  Pool Data% Meta% Devices                
  [lvol0_pmspare] VG  ewi-------  4.00m                  /dev/mapper/mpathap1(0)
  pool            VG  twima-tz--  1.00g      0.00  0.98  pool_tdata(0)
  [pool_tdata]    VG  Twi-ao----  1.00g                  /dev/mapper/mpathap1(1)
  [pool_tmeta]    VG  ewi-ao----  4.00m                  /dev/mapper/mpathhp2(0)
[root@grant-02 ~]# lvs -a -o +devices
  LV              VG  Attr       LSize  Pool Data% Meta% Devices                
  [lvol0_pmspare] VG  ewi-------  4.00m                  /dev/mapper/mpathap1(0)
  pool            VG  twima-tz--  1.00g      0.00  0.98  pool_tdata(0)
  [pool_tdata]    VG  Twi-ao----  1.00g                  /dev/mapper/mpathap1(1)
  [pool_tmeta]    VG  ewi-ao----  4.00m                  /dev/mapper/mpathfp2(0)
[root@grant-03 ~]# lvs -a -o +devices
  LV              VG  Attr       LSize  Pool Data% Meta% Devices                
  [lvol0_pmspare] VG  ewi-------  4.00m                  /dev/mapper/mpathhp1(0)
  pool            VG  twima-tz--  1.00g      0.00  0.98  pool_tdata(0)
  [pool_tdata]    VG  Twi-ao----  1.00g                  /dev/mapper/mpathhp1(1)
  [pool_tmeta]    VG  ewi-ao----  4.00m                  /dev/mapper/mpathcp2(0)


Version-Release number of selected component (if applicable):
2.6.32-502.el6.x86_64
lvm2-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
lvm2-libs-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
lvm2-cluster-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
udev-147-2.57.el6    BUILT: Thu Jul 24 08:48:47 CDT 2014
device-mapper-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-libs-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-event-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-event-libs-1.02.90-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014
device-mapper-persistent-data-0.3.2-1.el6    BUILT: Fri Apr  4 08:43:06 CDT 2014
cmirror-2.02.111-2.el6    BUILT: Mon Sep  1 06:46:43 CDT 2014


How reproducible:
Everytime

Comment 1 Corey Marthaler 2014-09-17 21:36:26 UTC
Created attachment 938646 [details]
-vvvv of the lvchange

Comment 3 Zdenek Kabelac 2014-11-26 20:12:06 UTC
Here we need to consider more things now with docker support to use 'initialized' but unused thin-pool.

ATM (with version 2.02.112) it's been disabled to create thin-pool with --minor - however now when we allowed 'public' use for thin-pool - we may need to consider to again enable support.

lvchange remained so far unchanged.

Comment 4 Zdenek Kabelac 2015-03-04 12:21:14 UTC
The fix here will disable support for  lvchange of --minor for thin-pool.

Minor support was purely oriented to support 'nfs' use-case where filesystem has to be located on a fixed minor device.

There is no use case of fixed minor  for thin-pool device.

Comment 5 Zdenek Kabelac 2015-03-18 13:11:32 UTC
lvchange of persistent majors/minors for pool volumes has been disabled with upstream commit:

https://www.redhat.com/archives/lvm-devel/2015-March/msg00075.html

Comment 7 Corey Marthaler 2015-05-01 20:15:30 UTC
Marking "verified" in the latest rpms. The changing of minor numbers is no longer allowed with pool volumes (on clustered vgs or not).

lvm2-2.02.118-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015
lvm2-libs-2.02.118-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015
lvm2-cluster-2.02.118-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015
udev-147-2.61.el6    BUILT: Mon Mar  2 05:08:11 CST 2015
device-mapper-1.02.95-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015
device-mapper-libs-1.02.95-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015
device-mapper-event-1.02.95-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015
device-mapper-event-libs-1.02.95-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015
device-mapper-persistent-data-0.3.2-1.el6    BUILT: Fri Apr  4 08:43:06 CDT 2014
cmirror-2.02.118-2.el6    BUILT: Wed Apr 15 06:34:08 CDT 2015


[root@host-082 ~]# lvchange -f -My --major 255 --minor 159 /dev/VG/pool
  Persistent major and minor numbers are not supported with pools.

Comment 8 errata-xmlrpc 2015-07-22 07:35:34 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.

https://rhn.redhat.com/errata/RHBA-2015-1411.html