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 1591603

Summary: blkid hangs on multipath device
Product: Red Hat Enterprise Linux 7 Reporter: Robin Cernin <rcernin>
Component: device-mapper-multipathAssignee: Ben Marzinski <bmarzins>
Status: CLOSED NOTABUG QA Contact: Lin Li <lilin>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.5CC: agk, bmarzins, heinzm, lilin, msnitzer, prajnoha, rcernin
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-11-12 19:40:49 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:

Description Robin Cernin 2018-06-15 05:22:04 UTC
Description of problem:

blkid hangs on multipath device

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

util-linux-2.23.2-43.el7.x86_64

multipath -ll |grep -B4 fault


36000d310055bc8000000000000000420 dm-102 COMPELNT,Compellent Vol  
size=1.0G features='1 queue_if_no_path' hwhandler='0' wp=rw
`-+- policy='service-time 0' prio=0 status=active
  |- 13:0:0:38 sdet 129:80  failed faulty running
  `- 14:0:0:38 sdeu 129:96  failed faulty running

36000d310055bc8000000000000000429 dm-94 COMPELNT,Compellent Vol  
size=1.0G features='1 queue_if_no_path' hwhandler='0' wp=rw
`-+- policy='service-time 0' prio=0 status=active
  |- 12:0:0:44 sded 128:80  failed faulty running
  `- 11:0:0:44 sdee 128:96  failed faulty running

# ps -elf | grep blkid
0 D root       41894       1  0  80   0 -  2183 blkdev 00:44 ?        00:00:00 /sbin/blkid -o udev -p /dev/dm-102
0 D root       42030       1  0  80   0 -  2183 blkdev 00:44 ?        00:00:00 /sbin/blkid -o udev -p /dev/dm-94
0 S root      519368  502913  0  80   0 - 28166 pipe_w 13:16 pts/27   00:00:00 grep --color=auto blkid

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 3 Zdenek Kabelac 2018-06-15 08:27:05 UTC
Is this issue easily reproducible ?

Is kernel reporting any failure ?

Is any other 'read' from multipath device working ?

Is there ANY path actually working ??
(since there is set 'queue_if_no_path' for MP device - with no working path there will be hanging processes trying to read/write)

IMHO from light overlook of reported case all seems to work as designed.

Comment 4 Ben Marzinski 2018-06-15 14:27:54 UTC
So, the likely issue here is that the default configuration for Compellent storage arrays is to queue forever (or until manual intervention happens) if there are no usable paths. These default configurations come directly from the storage vendors. We only change them if they are actually broken.

If want your queued IO to automatically fail back after a timeout, you can override this. In /etc/multipath.conf add a section that looks like this



devices {
        device {
                vendor "COMPELNT"
                product "Compellent Vol"
                no_path_retries <number_of_retries>
        }
}



By default, multipathd retries a failed path every 5 seconds, so the total length of time multipath would queue for, after the last path to your storage had failed, would be 5 * <number_of_retries>.

If you have multiple different types of devices, and you want them all to queue for a standard length of time, you can add a section that looks like this instead


devices {
        device {
                all_devs yes
                no_path_retries <number_of_retries>
        }
}

Let me know if that clears this up.

Comment 5 Robin Cernin 2018-08-09 05:12:28 UTC
Wouldn't it be better if we setup a timeout for blkid?

We have a script in OpenStack for ceph-disks that is running re-scan of the disks on regular basis, and I have seen situations where it actually bogged down the server by running too many blkid processes that were hang definitely.

Would there be actually any down-side to having such timeout implemented?

Comment 6 Ben Marzinski 2018-10-01 20:17:18 UTC
When multipath is set to queue forever, it won't return the IO until it can submit it.  So even if blkid could timeout (which is would probably have to do by using async IO), the IO would still by stuck on the device. It really seems like if you don't want that IO to queue forever, don't have multipath queue the IO forever.  The "all_devs" option above is what RHEV uses to deal with issues like this.