Bug 1319853
Summary: | -c option exits with 'requires a path to check' error, but path is there | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | mulhern <amulhern> |
Component: | device-mapper-multipath | Assignee: | Ben Marzinski <bmarzins> |
Status: | CLOSED ERRATA | QA Contact: | Lin Li <lilin> |
Severity: | unspecified | Docs Contact: | Steven J. Levine <slevine> |
Priority: | unspecified | ||
Version: | 7.2 | CC: | agk, bmarzins, heinzm, lilin, mgandhi, msnitzer, prajnoha |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | device-mapper-multipath-0.4.9-89.el7 | Doc Type: | Bug Fix |
Doc Text: |
Multipath now states that a path is `not a valid argument` for paths that do not belong to block devices
Previously, if you used a path to something that is not a valid block device, multipath would tell you that it `requires a path to check`, which is unhelpful. This is because multipath considered anything that is not a block device path or major:minor number to be a multipath alias. With this fix, multipath will not treat fully qualified paths to anything that is not a block devices as a multipath alias. As a result, multipath will state the that path is `not a valid argument` for paths that do not belong to block devices.
|
Story Points: | --- |
Clone Of: | Environment: | ||
Last Closed: | 2016-11-04 08:19:00 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
mulhern
2016-03-21 16:30:57 UTC
Update: The real root of the problem may be a confusion about whether the partition is a character or a block device. [mulhern-journal@megadeth pydevDAG]$ file /dev/sde* /dev/sde: block special /dev/sde1: character special [mulhern-journal@megadeth pydevDAG]$ ls /sys/class/block/sde* -d /sys/class/block/sde /sys/class/block/sde1 [mulhern-journal@megadeth pydevDAG]$ ls /sys/block/sde* -d /sys/block/sde For the record, I never took any action that should have resulted in these partitions being considered character devices. the device's subsytem value in udev is block. It may be that it is libudev that is causing this behavior, see related bz#1319870. Relevant entry in journal:
Mon 2016-03-21 13:10:52.002159 EDT [s=07d0dd3e450e447b8176fae6f6ca2172;i=26b1e9;b
=4a123904d9fd4e27883b8169b32e4f8b;m=115a15395e6;t=52e922dcc0b7e;x=e1915c976deb100
]
SYSLOG_FACILITY=3
_UID=0
_GID=0
_CAP_EFFECTIVE=1fffffffff
_BOOT_ID=4a123904d9fd4e27883b8169b32e4f8b
_MACHINE_ID=c2a1a2c9555048fab5453a08361c43dc
_HOSTNAME=megadeth.lab.bos.redhat.com
_TRANSPORT=syslog
_SYSTEMD_SLICE=system.slice
SYSLOG_IDENTIFIER=multipathd
_PID=47585
_COMM=multipathd
_EXE=/usr/sbin/multipathd
_CMDLINE=/sbin/multipathd
_SYSTEMD_CGROUP=/system.slice/multipathd.service
_SYSTEMD_UNIT=multipathd.service
PRIORITY=3
MESSAGE=sde1: failed to get path uid
_SOURCE_REALTIME_TIMESTAMP=1458580252002159
on calling:
multipathd add path /dev/sde1
> rm /dev/sde1
> partprobe /dev/sde
turns the partition device into a block device, but "multipathd add path /dev/sde1" has the same error as before.
Should have partprobed the multipath device /dev/dm-13. After that, was able to add both paths succesfully. However, the sysfs holders directory for the partition is still empty. Comment #7 was misleading. The partition device's holders directory should be empty, and is. The multipath device's holders directory should contain a single dm device corresponding to the partition on the device and it does. The entries in the udev database for these devices seem correct. So, the only problem that really exists, AFAICT, is that multipath -c /dev/<partition device> should do better than report the -c option requires a path to check when the path does, in fact, exist, even if that particular device file has somehow mutated and appears to be a character device file. The solution to this problem may or may not depend on a libudev solution (bz#1319870). You are correct that the issue is that the device isn't a block device. Multipath assumes that anything you pass it that is not a valid block device is an alias for a multipath device. Since aliases can't have "/" in them, there's no reason to worry about possible confusion here. I can make multipath return a more helpful error message in this case. Multipath now does more checking here, and will print '<string>' is not a valid argument if the argument is not valid. Rerpoduced on device-mapper-multipath-0.4.9-85.el7 # multipath -c /dev/sde1 Apr 23 14:49:00 | the -c option requires a path to check Verified on device-mapper-multipath-0.4.9-89.el7 # multipath -c /dev/sde1 Apr 23 08:55:32 | '/dev/sde1' is not a valid argument # multipath -l mpatha (360fff19abdd9552f8a36e5355226ba27) dm-0 EQLOGIC ,100E-00 size=50G features='0' hwhandler='0' wp=rw |-+- policy='service-time 0' prio=0 status=active | `- 3:0:0:0 sdb 8:16 active undef running `-+- policy='service-time 0' prio=0 status=enabled `- 4:0:0:0 sdc 8:32 active undef running [root@storageqe-84 device-mapper-multipath-0.4.9]# multipath -c /dev/sdb /dev/sdb is a valid multipath device path [root@storageqe-84 device-mapper-multipath-0.4.9]# multipath -c /dev/sdc /dev/sdc is a valid multipath device path test result: multipath will state the that path is "not a valid argument" for paths that don't belong to block devices. 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 |