White Papers

Useful tools
48 Dell EMC SC Series: Red Hat Enterprise Linux Best Practices | CML1031
5 Useful tools
The following native Linux tools can be used to identify and correlate volumes to their respective SC Series
devices.
5.1 The lsscsi command
The lsscsi command is a tool that parses information from the /proc and /sys pseudo filesystems into human
readable output. The lsscsi tool is installed using the following command.
# yum y install lsscsi
The following lsscsi example filters and displays only SC Series LUNs in alphabetically order. The first
column displays the [host:channel:target:lun] designation for each volume. The host number corresponds
to the local HBA hostX device file that the volume is mapped to. The channel number is the SCSI bus
address and is always zero (0). The target number correlates to the SC Series front-end ports (targets). The
LUN number represents the LUN ID of the volume on the SC Series controller where it is mapped.
# lsscsi | grep COMPELNT | sort -k7
[snip]
[1:0:0:1] disk COMPELNT Compellent Vol 0605 /dev/sdb
[1:0:2:1] disk COMPELNT Compellent Vol 0605 /dev/sdc
[1:0:3:1] disk COMPELNT Compellent Vol 0605 /dev/sdd
[1:0:3:2] disk COMPELNT Compellent Vol 0605 /dev/sde
[1:0:5:1] disk COMPELNT Compellent Vol 0605 /dev/sdf
[snip]
For RHEL 7 and newer, new options offer additional useful information about the LUNs such as LUN size and
WWPN. The WWPN contains the Serial Number or Device ID, prepended with a 3, of the SC Series volume
that can be found in the summary section of the volume in DSM GUI. See Figure 4.
# lsscsi is | grep COMPELNT
[6:0:0:0] disk COMPELNT Compellent Vol 0703 /dev/sdb
36000d31000fcaf0000000000000002c0 107GB
[6:0:1:0] disk COMPELNT Compellent Vol 0703 /dev/sdc
36000d31000fcaf0000000000000002c0 107GB
[15:0:0:0] disk COMPELNT Compellent Vol 0703 /dev/sdd
36000d31000fcaf0000000000000002c0 107GB
[15:0:1:0] disk COMPELNT Compellent Vol 0703 /dev/sde
36000d31000fcaf0000000000000002c0 107GB
5.2 /usr/bin/rescan-scsi-bus.sh
The rescan-scsi-bus.sh script is installed with the sg3_util package. The script provides an easy way to
scan, discover, add and remove SCSI devices on the system.
Note: The options vary on different Red Hat Linux versions. Consult the vendor documentation for details.
Scan all targets on the system:
# rescan-scsi-bus.sh a