Table of Contents

FC-HBA

Unter /sys/class/fc_host/ sind die HBA's aufgelistet:

cd /sys/class/fc_host
ls -al
lrwxrwxrwx 1 root root 0 May  8 19:43 host7 -> ../../devices/pci0000:80/0000:80:02.0/0000:86:00.0/host7/fc_host/host7
lrwxrwxrwx 1 root root 0 May  8 19:43 host8 -> ../../devices/pci0000:80/0000:80:02.0/0000:86:00.1/host8/fc_host/host8

Hier sind 2 FC-Ports vorhanden (host7 + host8)

WWN von FC-HBA auslesen

die WWN von Port 1 (host7) auslesen:

cd /sys/class/fc_host/host7
cat port_name
0x0123456789abcdef

LUN zu Device Zuordnung

ls -l /dev/disk/by-path
lrwxrwxrwx. 1 root root  9 May  8 17:43 pci-0000:00:1f.2-scsi-0:0:0:0 -> ../../sr0
lrwxrwxrwx. 1 root root  9 May  8 17:43 pci-0000:1b:00.0-scsi-0:2:0:0 -> ../../sda
lrwxrwxrwx. 1 root root 10 May  8 17:43 pci-0000:1b:00.0-scsi-0:2:0:0-part1 -> ../../sda1
lrwxrwxrwx. 1 root root 10 May  8 17:43 pci-0000:1b:00.0-scsi-0:2:0:0-part2 -> ../../sda2
lrwxrwxrwx. 1 root root 10 May  8 17:44 pci-0000:86:00.0-fc-0x500507680c311d7b-lun-0 -> ../../sdca
lrwxrwxrwx. 1 root root 10 May  8 17:44 pci-0000:86:00.0-fc-0x500507680c311d8d-lun-0 -> ../../sdbp
lrwxrwxrwx. 1 root root 10 May  8 17:44 pci-0000:86:00.0-fc-0x500507680c311e00-lun-0 -> ../../sdat
lrwxrwxrwx. 1 root root 10 May  8 17:44 pci-0000:86:00.0-fc-0x500507680c311e07-lun-0 -> ../../sdbe
lrwxrwxrwx. 1 root root  9 May  8 17:43 pci-0000:86:00.1-fc-0x500507680c121d7b-lun-0 -> ../../sdx
lrwxrwxrwx. 1 root root  9 May  8 17:43 pci-0000:86:00.1-fc-0x500507680c121d8d-lun-0 -> ../../sdm
lrwxrwxrwx. 1 root root 10 May  8 17:43 pci-0000:86:00.1-fc-0x500507680c121e00-lun-0 -> ../../sdai
lrwxrwxrwx. 1 root root  9 May  8 17:43 pci-0000:86:00.1-fc-0x500507680c121e07-lun-0 -> ../../sdb

Hier sind zwei LUNs von zwei unterschiedlichen Storage-Systemen (500507680c311 + 500507680c121) mit jeweils 4 Pfaden sichtbar.

Mit lsblk werden die Partitionen und die Major + Minor Nummer der LUN angezeigt.

lsblk
NAME                          MAJ:MIN   RM   SIZE RO TYPE MOUNTPOINT
sda                             8:0      0 557.9G  0 disk
|-sda1                          8:1      0   250M  0 part /boot
`-sda2                          8:2      0 557.6G  0 part
  |-vg_name-lv_root (dm-0) 253:0      0    40G  0 lvm  /
  |-vg_name-lv_swap (dm-1) 253:1      0   128G  0 lvm  [SWAP]
  `-vg_name-lv_tmp (dm-2)  253:2      0    10G  0 lvm  /tmp
sdca                           68:224    0    50G  0 disk
|-sdca3                        68:227    0    50G  0 part
`-sdca8                        68:232    0    50G  0 part
sdbp                           68:48     0    50G  0 disk
|-sdbp3                        68:51     0    50G  0 part
`-sdbp8                        68:56     0    50G  0 part
...

SCSI Devices

Alle SCSI-Devices anzeigen:
cat /proc/scsi/scsi

SCSI Log-Level

Log-Level anzeigen:
cat /proc/sys/dev/scsi/logging_level

Log-Level erhöhen:
echo 9411 > /proc/sys/dev/scsi/logging_level

QLogic Kernel Modul Log-Level

Log-Level anzeigen:
cat /sys/module/qla2xxx/parameters/ql2xextended_error_logging

Log-Level erhöhen:
echo -n 0x7fffffff > /sys/module/qla2xxx/parameters/ql2xextended_error_logging