From the Solaris command line can you tell if a network cable is physically attached?

1

Is there a command I can type from the command line to tell if there is a physical cable plugged into a network port?

Craig

Posted 2010-09-20T15:51:15.340

Reputation: 11

Answers

1

Solaris 10:

# dladm show-dev
nxge0           link: down      speed: 0     Mbps       duplex: unknown
nxge1           link: up        speed: 1000  Mbps       duplex: full

OpenSolaris/OpenIndiana/Solaris 11:

# dladm show-phys
LINK         MEDIA                STATE      SPEED  DUPLEX    DEVICE
rtls0        Ethernet             up         100    full      rtls0
rtls1        Ethernet             down       0      unknown   rtls1

jlliagre

Posted 2010-09-20T15:51:15.340

Reputation: 12 469

0

kstat -p :::link_up

will show if the card is active as the OS sees it -- or not. It is possible to be "plugged in" and not configured or the connection has problems, so this is not goof proof.

jim mcnamara

Posted 2010-09-20T15:51:15.340

Reputation: 769