find WWN Number of HBA Card in Redhat Linux & CentOS
If our Linux box is connected to one or more SAN switch via Fibre HBA cards. So it becomes very important to the Storage Team that they assign the storage to the correct Servers via WWN numbers of Fibre HBA Cards. So To find the WWNnumber of HBA card in linux use the below command :
# systool -c fc_host -v | grep "port_name"
Sample Output :
port_name = "0x5001438001347fdc" port_name = "0x5001438001347fde" port_name = "0x50014380013471f0" port_name = "0x50014380013471f2"
systool command is provided by the rpm package "sysfsutils"
Alternate Method :
# cat /sys/class/scsi_host/hostN/device/fc_host/hostN/port_name
Where “N” is the number of device for your fiber HBAs.