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 1299648 - kpartx on multipath device returning before creation of dm partition device
Summary: kpartx on multipath device returning before creation of dm partition device
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: device-mapper-multipath
Version: 7.1
Hardware: x86_64
OS: Linux
high
high
Target Milestone: rc
: ---
Assignee: Ben Marzinski
QA Contact: Lin Li
Steven J. Levine
URL:
Whiteboard:
Depends On: 1254692
Blocks: 1203710 1295577 1313485 1330480
TreeView+ depends on / blocked
 
Reported: 2016-01-18 21:46 UTC by Ben Marzinski
Modified: 2021-09-03 12:03 UTC (History)
13 users (show)

Fixed In Version: device-mapper-multipath-0.4.9-87.el7
Doc Type: Bug Fix
Doc Text:
The `kpartx` tool no longer returns before devices are created Previously, by default the `kpartx` tool returned without waiting for devices to be created. This was a source of confusion for users who would expect the devices to exist immediately after `kpartx` returned. With this update, `kpartx` by default now waits until the devices are created before returning.
Clone Of: 1254692
: 1330480 (view as bug list)
Environment:
Last Closed: 2016-11-04 08:16:24 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:2536 0 normal SHIPPED_LIVE device-mapper-multipath bug fix and enhancement update 2016-11-03 14:18:10 UTC

Comment 1 Ben Marzinski 2016-02-26 22:41:09 UTC
kpartx now runs it sync mode by default.

Comment 6 Lin Li 2016-04-25 11:32:22 UTC
Reproduced on device-mapper-multipath-0.4.9-77.el7
1). # rpm -qa | grep kpartx
    kpartx-0.4.9-77.el7.x86_64
2). # rpm -qa | grep multipath
device-mapper-multipath-libs-0.4.9-77.el7.x86_64
device-mapper-multipath-0.4.9-77.el7.x86_64
device-mapper-multipath-sysvinit-0.4.9-87.el7.x86_64
3). Execute script mentioned to reproduce
2+0 records in
2+0 records out
2147483648 bytes (2.1 GB) copied, 2.42782 s, 885 MB/s
sfdisk: Warning: /var/tmp/imgtst.img is not a block device

sfdisk: Disk /var/tmp/imgtst.img: cannot get geometry


Disk /var/tmp/imgtst.img: 261 cylinders, 255 heads, 63 sectors/track
sfdisk:  /var/tmp/imgtst.img: unrecognized partition table type

Old situation:
sfdisk: No partitions found

New situation:
Units: cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/var/tmp/imgtst.img1          0+    259     260-   2088449+  83  Linux
/var/tmp/imgtst.img2          0       -       0          0    0  Empty
/var/tmp/imgtst.img3          0       -       0          0    0  Empty
/var/tmp/imgtst.img4          0       -       0          0    0  Empty
Warning: no primary partition is marked bootable (active)
This does not matter for LILO, but the DOS MBR will not boot this disk.
Successfully wrote the new partition table


If you created or changed a DOS partition, /dev/foo7, say, then use dd(1)
to zero the first 512 bytes:  dd if=/dev/zero of=/dev/foo7 bs=512 count=1
(See fdisk(8).)
add map loop0p1 (253:5): 0 4176899 linear /dev/loop0 1
NO: 313085087
NO: 316822069
NO: 319848978
NO: 323203567
NO: 326373389
NO: 329500389
NO: 332653052
NO: 336869907
NO: 339931134
NO: 343157047
NO: 346240276
NO: 349212883
NO: 352183837
NO: 355079186
NO: 358050272
OK: 361472619



Verified on device-mapper-multipath-0.4.9-87.el7
1). # rpm -qa | grep kpartx
kpartx-0.4.9-87.el7.x86_64
2). # rpm -qa | grep multipath
device-mapper-multipath-0.4.9-87.el7.x86_64
device-mapper-multipath-sysvinit-0.4.9-87.el7.x86_64
device-mapper-multipath-libs-0.4.9-87.el7.x86_64
3). Execute script mentioned to reproduce
2+0 records in
2+0 records out
2147483648 bytes (2.1 GB) copied, 1.34744 s, 1.6 GB/s
sfdisk: Warning: /var/tmp/imgtst.img is not a block device

sfdisk: Disk /var/tmp/imgtst.img: cannot get geometry


Disk /var/tmp/imgtst.img: 261 cylinders, 255 heads, 63 sectors/track
sfdisk:  /var/tmp/imgtst.img: unrecognized partition table type

Old situation:
sfdisk: No partitions found

New situation:
Units: cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/var/tmp/imgtst.img1          0+    259     260-   2088449+  83  Linux
/var/tmp/imgtst.img2          0       -       0          0    0  Empty
/var/tmp/imgtst.img3          0       -       0          0    0  Empty
/var/tmp/imgtst.img4          0       -       0          0    0  Empty
Warning: no primary partition is marked bootable (active)
This does not matter for LILO, but the DOS MBR will not boot this disk.
Successfully wrote the new partition table


If you created or changed a DOS partition, /dev/foo7, say, then use dd(1)
to zero the first 512 bytes:  dd if=/dev/zero of=/dev/foo7 bs=512 count=1
(See fdisk(8).)
add map loop0p1 (253:5): 0 4176899 linear /dev/loop0 1
OK: 114357926



Test result: device mapper partition device is created prior to the kpartx command returning

Comment 12 errata-xmlrpc 2016-11-04 08:16:24 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-2016-2536.html


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