Red Hat Bugzilla – Bug 1311659
Add multipath option to disable kpartx partition creation
Last modified: 2016-11-04 04:18:18 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.
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
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
change to verified according to comment 2 and comment 4.
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