Skip to content

How to obtain WWNs of Fibre Channel Cards in Windows, Linux and Netware 6

Windows

While you could use the tools provided by vendors (such as SANSurfer for QLogic, ...), there is a Microsoft tool available that will give various information about Fibre Channel Cards in Windows.
This tool is available for all architectures and can be downloaded at this link:

http://www.microsoft.com/downloads/details.aspx?FamilyID=73d7b879-55b2-4...

Linux

I've made a very simple script that prints WWNs for QLogic and Emulex cards. This script will search in pre-defined directories where drivers for these cards will store their FCC information.

#!/bin/bash
if [ -d "/sys/class/fc_host" ] ; then
	cd /sys/class/fc_host
	ls -w1 | while read i ; do
		if [ -f "$i/port_name" ] ; then
			echo -n "wwn: "
			cat $i/port_name
		fi
	done
elif [ -d "/proc/scsi/qla2xxx" ] ; then
	cd /proc/scsi/qla2xxx
	ls -w1 | while read i ; do
		if [ -f "$i" ] ; then
			echo -n "wwn: "
			grep -E "scsi-qla.-adapter-port" $i|cut -d= -f2|cut -d\; -f1
		fi
	done
fi

Novell Netware

Currently I'm only aware how to find FCC information for QLogic cards. A module cfg.nlm is packages with the QLXX driver, and information can be retrieved by loading this module:

cfg.nlm /I