summaryrefslogtreecommitdiff
path: root/lib/device/dev-mpath.c
diff options
context:
space:
mode:
authorDavid Teigland <teigland@redhat.com>2022-02-10 14:00:25 -0600
committerDavid Teigland <teigland@redhat.com>2022-06-09 11:32:40 -0500
commit08a5619a1d7a5a8dd6e0df6e4dedec47ce2533b7 (patch)
treeff94e1f2d9da86ab0cf45cce34a3e22c07125e9f /lib/device/dev-mpath.c
parentdf2b1555aff71452cde156badec70117065c9e2c (diff)
downloadlvm2-08a5619a1d7a5a8dd6e0df6e4dedec47ce2533b7.tar.gz
devices file: do not clear PVID of unread devices
In a certain disconnected state, a block device is present on the system, can be opened, reports a valid size, reports the correct device id (wwid), and matches a devices file entry. But, reading the device can still fail. In this case, device_ids_validate() was misinterpreting the read error as the device having no data/label on it (and no PVID). The validate function would then clear the PVID from the devices file entry for the device, thinking that it was fixing the devices file (making it consistent with the on disk state.) Fix this by not attempting to check and correct a devices file entry that cannot be read. Also make this case explicit in the hints validation code (which was doing the right thing but indirectly.)
Diffstat (limited to 'lib/device/dev-mpath.c')
0 files changed, 0 insertions, 0 deletions