How to List all Network cards

Hi,

I'm looking for a command to be able to list all my network cards available on my server.

With the command "ifconfig - a", I can only see to configured network card(s)

Any idea ? :confused:

Thanks a lot for your help,

Fabien

You can try this:

root@sun # cat /etc/path_to_inst | grep -i network
"/pci@1f,0/pci@1,1/network@1,1" 0 "hme"
"/pci@1f,0/pci@1,1/network@3,1" 1 "hme"

this is a server having two hme interfaces...

If it don�t work for you , you can try to enter each possible name:

cat /etc/path_to_inst | grep -i hme

cat /etc/path_to_inst | grep -i qfe

cat /etc/path_to_inst | grep -i eri

cat /etc/path_to_inst | grep -i bge

cat /etc/path_to_inst | grep -i ce

been awhile since I've done this so could be wrong. But a probe_all (?) from the OBP would also should what is connected.

I think show_nets is what you are thinking of.

/usr/platform/`uname -i`/sbin/prtdiag | grep network

prtdiag will show all of the I/O cards. However the precise format varies from system to system. On an Enterprise 420R, an hme card shows up with "network-SUNW,hme" on the line. No so with an Ultra 2. There we just get "SUNW,hme". This issue also prevents "grep network /etc/path_to_inst" which might otherwise look promising. It might be that this works with PCI bus systems and fails with Sbus systems, but I'm not sure. But then again, Sun has other buses.