Operating System - Linux
1753599 Members
6513 Online
108796 Solutions
New Discussion юеВ

how to find fiberchannel card status on linux

 
SOLVED
Go to solution
Jagadesh_2
Regular Advisor

how to find fiberchannel card status on linux

Admins,

i need to find the fiberchannel card / status on all linux servers. Could you please let me know the command for the same

Thanks & Regards
Jagadesh
7 REPLIES 7
Ivan Ferreira
Honored Contributor

Re: how to find fiberchannel card status on linux

If your adapter is qlogic, you can use sansurfer. There is a sansurfer "CLI" version for command line instead of graphic view.

If you HBA is emulex, then you can try with Emulex HBAs anywhere.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Kevin Wright
Honored Contributor

Re: how to find fiberchannel card status on linux

cat /proc/scsi//*
if using the psp, run adapter_info.
skt_skt
Honored Contributor

Re: how to find fiberchannel card status on linux

#lspci|grep -i fibre
04:04.0 Fibre Channel: QLogic Corp. QLA2312 Fibre Channel Adapter (rev 02)
09:02.0 Fibre Channel: QLogic Corp. QLA2312 Fibre Channel Adapter (rev 02)

Below will give more detailed info

# cat /proc/scsi/qla2300/[1-2]*


Asif Sharif
Honored Contributor

Re: how to find fiberchannel card status on linux

Hi Jagadesh,

# lspci | grep Fibre
80:02.0 Fibre Channel: Emulex Corporation Helios-X LightPulse Fibre Channel Host Adapter (rev 01)
a0:02.0 Fibre Channel: QLogic Corp. QLA2312 Fibre Channel Adapter (rev 03)
a0:02.1 Fibre Channel: QLogic Corp. QLA2312 Fibre Channel Adapter (rev 03)

http://docs.hp.com/en/5991-7635/ch03s04.html

Regards,
Asif Sharif
Regards,
Asif Sharif
Jagadesh_2
Regular Advisor

Re: how to find fiberchannel card status on linux

Thanks for you responses.

I tried all the above commands and it has not returned any value / information.

/usr/sbin/adapter_info
/sbin/lspci |grep -i fiber

under /proc/scsi i can find only these below files

cd /proc/scsi
ls -l
total 0
-r--r--r-- 1 root root 0 Nov 6 09:21 device_info
-r--r--r-- 1 root root 0 Nov 6 09:21 scsi
dr-xr-xr-x 2 root root 0 Nov 6 09:21 sg

cd sg
ls -l
-rw-r--r-- 1 root root 0 Nov 6 09:22 allow_dio
-r--r--r-- 1 root root 0 Nov 6 09:22 debug
-rw-r--r-- 1 root root 0 Nov 6 09:22 def_reserved_size
-r--r--r-- 1 root root 0 Nov 6 09:22 device_hdr
-r--r--r-- 1 root root 0 Nov 6 09:22 devices
-r--r--r-- 1 root root 0 Nov 6 09:22 device_strs
-r--r--r-- 1 root root 0 Nov 6 09:22 version

Please suggest.
Hemmetter
Esteemed Contributor
Solution

Re: how to find fiberchannel card status on linux

Hi Jagadesh,

For some HBAs and new kernels you find the information under /sys instead of /proc:

for Emulex HBA and Kernel 2.6 you can try:
$ uname -r
2.6.16.46-0.12-smp

$ cd /sys/class/scsi_host/
$ cat host?/modeldesc
Emulex LPe11002 4Gb 2-port PCIe Fibre Channel Adapter
Emulex LPe11002 4Gb 2-port PCIe Fibre Channel Adapter
Emulex LPe1150 4Gb PCIe Fibre Channel Adapter

$ cat /host?/state
Link Up - Ready:
Fabric
Link Down
Link Up - Ready:
Fabric



rgds
HGH
Kevin Wright
Honored Contributor

Re: how to find fiberchannel card status on linux

most likely you don't have hba's installed on this server then. adapter_info/lspci should show you the devices if they are installed.