Tag Archives: fc_host

How To Get The WWID of an HBA with Redhat Enterprise Linux

A bit of a problem presented itself to me the other day. A colleague called me on my mobile and asked me what the WWN of the first HBA in one of our servers was (He pointed out to me that the label on the HBA with this number on it was unreadable). Well, i don’t know about you but i don’t commit that kind of information to memory. So, what to do.. I scratched my head, had a coffee, nosed around the internet for a while and eventually stumbled across this solution.. here goes.. oh, I should tell you the Linux we use is Redhat Enterprise Linux 5.5 ..

Start a terminal sesson on your server as root.


type systool -vc fc_host


you should get some output like this:

Class Device = “host1”


Class Device path = “/sys/class/fc_host/host1”


fabric_name = “0x100000051e36281c”


issue_lip =


node_name = “0x2000001b328709b2”


port_id = “0x018680”


port_name = “0x2100001b328709b2”


port_state = “Online”


port_type = “NPort (fabric via point-to-point)”


speed = “4 Gbit”


supported_classes = “Class 3”


supported_speeds = “1 Gbit, 2 Gbit, 4 Gbit”


symbolic_name = “QLE2462 FW:v5.03.02 DVR:v8.03.01.04.05.05-k”


system_hostname = “”


tgtid_bind_type = “wwpn (World Wide Port Name)”


uevent =

[…SNIP]

Anyway, the line you’re after is the port_name. If you chop ‘0x’ from the front of the port_name value you are left with the WWID/Number of your HBA. It’ll look more like a WWID if you insert a ‘:’ after every second character. So for me 0x2100001b328709b2 becomes 2100001b328709b2 which then becomes 21:00:00:1b:32:87:09:b2.

Voila, you have a WWID.