This section describes LUN identification for the Linux host system.
# cat proc/scsi/scsi # cat /proc/scsi/scsi | less Attached devices: Host: scsi1 Channel: 00 Id: 00 Lun: 00 Vendor: IBM-PSG Model: DDYS-T36950M M Rev: S96E Type: Direct-Access ANSI SCSI revision: 03 Host: scsi1 Channel: 00 Id: 08 Lun: 00 Vendor: IBM Model: YGLv3 S2 Rev: 0 Type: Processor ANSI SCSI revision: 02 Host: scsi4 Channel: 00 Id: 00 Lun: 00 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05 Host: scsi4 Channel: 00 Id: 00 Lun: 01 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05 Host: scsi4 Channel: 00 Id: 00 Lun: 02 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05 Host: scsi4 Channel: 00 Id: 00 Lun: 03 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05 Host: scsi4 Channel: 00 Id: 00 Lun: 04 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05 Host: scsi4 Channel: 00 Id: 00 Lun: 05 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05 Host: scsi4 Channel: 00 Id: 00 Lun: 06 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05 Host: scsi4 Channel: 00 Id: 00 Lun: 07 Vendor: IBM Model: 1750500 Rev: 5.17 Type: Direct-Access ANSI SCSI revision: 05
Starting with the Linux 2.6 kernels, the /proc filesystem is migrating over to the improved /sys filesystem. The /sys filesystem supports dynamic changes such as adding and removing LUNs without requiring a host adapter driver reload or rebooting the host system. Typically, more accurate information about what SCSI devices are recognized by the host system is attained by checking the contents of the directory /sys/class/scsi_host/hostN, where N is host adapter ID number. lsscsi is a user-space tool that uses the information in /sys to display a summarized list of all the recognized devices. This tool may not currently be available on all Linux 2.6 distribution kernels.