https://bugzilla.novell.com/show_bug.cgi?id=677251 https://bugzilla.novell.com/show_bug.cgi?id=677251#c17 --- Comment #17 from Marius Tomaschewski <mt@novell.com> 2011-03-11 10:11:37 UTC --- OK, I interviewed Hannes a bit by phone. - A vlan interface is not mandatory for FCoE -- it may also go directly over the eth interface - The interface dir may be contain also subdirs with another host numbers, that is, it is needed to check if there is a /sys/class/net/$v/host* dir (at least host[0-9]+). Better seems to check if there are /sys/class/net/$ifname/host*/fc_host directories. So this code should be better to show all interfaces used by FCoE: for i in $(ls -1 /sys/class/net/ 2>/dev/null) ; do d="/sys/class/net/$i" test "x$i" != x -a -d "$d" || continue h=$(ls -1d "$d/"host*/fc_host 2>/dev/null) if test "x$h" != x ; then if test -f "/proc/net/vlan/$i" ; then e='' while read key val ; do case $key in Device:) e=$val ;; esac done < "/proc/net/vlan/$i" 2>/dev/null echo "$i $e" else echo "$i" fi fi done It ouputs "<vlan-interface> <ether device>" in case FCoE makes use of a vlan interface, and "<interface>" when not. OK, Martin, your turn :-) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.