Bug 1311659 - Add multipath option to disable kpartx partition creation
Add multipath option to disable kpartx partition creation
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: device-mapper-multipath (Show other bugs)
7.2
Unspecified Unspecified
high Severity unspecified
: rc
: ---
Assigned To: Ben Marzinski
Lin Li
Steven J. Levine
:
Depends On: 1310320
Blocks: 1386360 1388229
  Show dependency treegraph
 
Reported: 2016-02-24 12:00 EST by Ben Marzinski
Modified: 2016-11-04 04:18 EDT (History)
12 users (show)

See Also:
Fixed In Version: device-mapper-multipath-0.4.9-91.el7
Doc Type: Enhancement
Doc Text:
New `skip_kpartx` configuration option to allow skipping `kpartx` partition creation The `skip_kpartx` option has been added to the defaults, devices, and multipaths sections of the `multipath.conf` file. When this option is set to `yes`, multipath devices that are configured with `skip_kpartx` will not have any partition devices created for them. This allows users to create a multipath device without creating partitions, even if the device has a partition table. The default value of this option is `no`.
Story Points: ---
Clone Of: 1310320
: 1386360 (view as bug list)
Environment:
Last Closed: 2016-11-04 04:18:18 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)
Comment 1 Ben Marzinski 2016-06-03 11:49:25 EDT
I've added an option "skip_kpartx" to the defaults, devices, and multipaths section of multipath.conf. Setting this on a device will disable kpartx handling. This works using udev rules and the DM_SUBSYSTEM_UDEV_FLAG1, as I explained above.
Comment 2 Lin Li 2016-06-30 10:57:06 EDT
Verified on device-mapper-multipath-0.4.9-91.el7
#man multipath.conf
defaults section
       skip_kpartx      If set to yes , kpartx will not automatically create partitions on the device. The default is no

multipaths section
       The following attributes are optional; if not set the default values are taken from the defaults or devices section:
              skip_kpartx

devices section
       The following attributes are optional; if not set the default values are taken from the defaults section:
              skip_kpartx
Comment 4 Lin Li 2016-07-07 08:59:53 EDT
Verified on device-mapper-multipath-0.4.9-91.el7
1. #edit /etc/multipath.conf
defaults {
        find_multipaths yes
        user_friendly_names yes
        prio weightedpath
        prio_args "wwn 0x20000000c9a02834:.*:.*:.* 30"
        skip_kpartx yes
}

2.# multipath -r
reload: 360a98000324669436c2b45666c567942 undef NETAPP  ,LUN             
size=20G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:0   sdb  8:16   active ready running
| `- 6:0:1:0   sdz  65:144 active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:0   sdj  8:144  active ready running
  `- 6:0:0:0   sdr  65:16  undef ready running
reload: 360a98000324669436c2b45666c567944 undef NETAPP  ,LUN             
size=2.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:1   sdc  8:32   active ready running
| `- 6:0:1:1   sdaa 65:160 active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:1   sdk  8:160  active ready running
  `- 6:0:0:1   sds  65:32  undef ready running
reload: 360a98000324669436c2b45666c567946 undef NETAPP  ,LUN             
size=2.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:2   sdd  8:48   active ready running
| `- 6:0:1:2   sdab 65:176 active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:2   sdl  8:176  active ready running
  `- 6:0:0:2   sdt  65:48  undef ready running
reload: 360a98000324669436c2b45666c596e65 undef NETAPP  ,LUN             
size=5.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:225 sdi  8:128  active ready running
| `- 6:0:1:225 sdag 66:0   active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:225 sdq  65:0   active ready running
  `- 6:0:0:225 sdy  65:128 undef ready running
reload: 360a98000324669436c2b45666c567948 undef NETAPP  ,LUN             
size=2.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:3   sde  8:64   active ready running
| `- 6:0:1:3   sdac 65:192 active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:3   sdm  8:192  active ready running
  `- 6:0:0:3   sdu  65:64  undef ready running
reload: 360a98000324669436c2b45666c56794a undef NETAPP  ,LUN             
size=2.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:4   sdf  8:80   active ready running
| `- 6:0:1:4   sdad 65:208 active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:4   sdn  8:208  active ready running
  `- 6:0:0:4   sdv  65:80  undef ready running
reload: 360a98000324669436c2b45666c596f54 undef NETAPP  ,LUN             
size=5.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:5   sdg  8:96   active ready running
| `- 6:0:1:5   sdae 65:224 active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:5   sdo  8:224  active ready running
  `- 6:0:0:5   sdw  65:96  undef ready running
reload: 360a98000324669436c2b45666c596f56 undef NETAPP  ,LUN             
size=5.0G features='3 queue_if_no_path pg_init_retries 50' hwhandler='0' wp=undef
|-+- policy='service-time 0' prio=50 status=undef
| |- 5:0:0:6   sdh  8:112  active ready running
| `- 6:0:1:6   sdaf 65:240 active ready running
`-+- policy='service-time 0' prio=10 status=undef
  |- 5:0:1:6   sdp  8:240  active ready running
  `- 6:0:0:6   sdx  65:112 undef ready running
Comment 5 Lin Li 2016-07-07 09:01:42 EDT
change to verified according to comment 2 and comment 4.
Comment 7 errata-xmlrpc 2016-11-04 04:18:18 EDT
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-2016-2536.html

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