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.
DescriptionNathaniel Weddle
2021-11-24 22:05:08 UTC
Description of problem:
Running blkid and tareting non-block device fails to complete (no RC). I've specifically noted this failure against /dev/hipraw devices. I've not reproduced against any other devices I've tried but it's possible I've missed some.
Per man page:
~~~
RETURN CODE
If the specified device or device addressed by specified token (option --match-token) was found and it's possible to gather
any information about the device, an exit code 0 is returned. Note the option --match-tag filters output tags, but it does
not affect return code.
If the specified token was not found, or no (specified) devices could be identified, or it is impossible to gather any
information about the device identifiers or device content an exit code of 2 is returned.
For usage or other errors, an exit code of 4 is returned.
If an ambivalent probing result was detected by low-level probing mode (-p), an exit code of 8 is returned.
~~~
Version-Release number of selected component (if applicable):
util-linux-2.32.1-24.el8.x86_64 and earlier
How reproducible:
# blkid /dev/hipraw*
Actual results:
Have to interrupt (ctrl+c) to return to command prompt
Expected results:
exit code of 2 is returned (if I'm readin the man page correctly) and drops to command prompt.
Additional info:
Initial issue was found because CU ran:
# blkid /dev/*
I'd like to amend my initial expectation here as the RC's are probably only specific to block devices. There is no way for blkid to force a device to issue and RC. Maybe adding a timeout so that if blkid ioctl goes without a response from kernel for some time, it prints a timeout failure on the device and drops to command prompt or continues with the next device if multiple devices are being queried.
How this presented here was this.
The customer ran blkid /dev/* and hit the non block device, /dev/port file.
This crashes a VMware guest so we told them its not a good idea to run this the way they did.
Nathan was able to also show that /dev/hidraw0 hangs when touched.
The idea here is to maybe change blkid such that if a wildcard is presented, its only block devices that get probed and the others are
ignored.
Seem like a simple change as we already have the file names and check the file type to see if its a block device.
Regards
Laurence
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 (util-linux bug fix and enhancement update), 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://access.redhat.com/errata/RHBA-2022:2100
Description of problem: Running blkid and tareting non-block device fails to complete (no RC). I've specifically noted this failure against /dev/hipraw devices. I've not reproduced against any other devices I've tried but it's possible I've missed some. Per man page: ~~~ RETURN CODE If the specified device or device addressed by specified token (option --match-token) was found and it's possible to gather any information about the device, an exit code 0 is returned. Note the option --match-tag filters output tags, but it does not affect return code. If the specified token was not found, or no (specified) devices could be identified, or it is impossible to gather any information about the device identifiers or device content an exit code of 2 is returned. For usage or other errors, an exit code of 4 is returned. If an ambivalent probing result was detected by low-level probing mode (-p), an exit code of 8 is returned. ~~~ Version-Release number of selected component (if applicable): util-linux-2.32.1-24.el8.x86_64 and earlier How reproducible: # blkid /dev/hipraw* Actual results: Have to interrupt (ctrl+c) to return to command prompt Expected results: exit code of 2 is returned (if I'm readin the man page correctly) and drops to command prompt. Additional info: Initial issue was found because CU ran: # blkid /dev/*