diff options
author | Tony Hutter <[email protected]> | 2021-02-20 20:17:45 -0800 |
---|---|---|
committer | GitHub <[email protected]> | 2021-02-20 20:17:45 -0800 |
commit | 7e56b05058c8d2af2b5bc8b0b1475d9fdd6cd7dc (patch) | |
tree | 80f72c9dd2646e7c3e04c8b1c0dc9b0802ccbdfc /lib/libzfs/THIRDPARTYLICENSE.openssl.descrip | |
parent | c0801bf35a09623a8f4422530550266c9fa143b5 (diff) |
Better zfs_get_enclosure_sysfs_path() enclosure support
A multpathed disk will have several 'underlying' paths to the disk. For
example, multipath disk 'dm-0' may be made up of paths:
/dev/{sda,sdb,sdc,sdd}. On many enclosures those underlying sysfs
paths will have a symlink back to their enclosure device entry
(like 'enclosure_device0/slot1'). This is used by the
statechange-led.sh script to set/clear the fault LED for a disk, and
by 'zpool status -c'.
However, on some enclosures, those underlying paths may not all have
symlinks back to the enclosure device. Maybe only two out of four
of them might.
This patch updates zfs_get_enclosure_sysfs_path() to favor returning
paths that have symlinks back to their enclosure devices, rather
than just returning the first path.
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Tony Hutter <[email protected]>
Closes #11617
Diffstat (limited to 'lib/libzfs/THIRDPARTYLICENSE.openssl.descrip')
0 files changed, 0 insertions, 0 deletions