Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

network adapter(s) - is cabled or not?

Status
Not open for further replies.

ogniemi

Technical User
Nov 7, 2003
1,041
0
0
PL
The is one network cable connected to a 2port network adapter. The machine is located in DC so I can't see which one is cabled. No network is configured on the system (new preinstalled machine).

Can I remotely recognize to whih ent the cable is plugged in to configure exactly this one? Is there a way?

I would like to avoid configuring both ones to determine the one I am looking for.

entstat doesn't help.
 
Hi

Open a hmc Terminal ( seriell )

try entstat -d ent0 | grep Media -> running ?

 
script form:

Code:
lsdev -Ccadapter -Fname|grep "^ent"|while read adp
do
 speed_mode=$(entstat -d $adp|grep '^Media Speed Running: '|cut -d' ' -f4-)
 if [ "${speed_mode}" = "Unknown" ]
 then
  echo "${adp} is not plugged in"
 else
  echo "${adp} is plugged in: ${speed_mode}"
 fi
done

HTH,

p5wizard
 
p5wizard,

it doesn't help... one of below ent's is cabled with switch but your script says that noone is...

ent0 is not plugged in
ent1 is not plugged in


this is a specific case when ent is yet not configured (but cabled) and I would like to ensure which one is cabled and configure exactly that one - not guessing...
 
Well, if you have (remote) access to the switch it is plugged in to, perhaps you can find de HW address and so deduce which of the two ethernet ports it is...

HTH,

p5wizard
 
You can use this command "netstat -v en0 | grep -i link". If you see link status as "up" you are connected to a switch that has the port enabled. If you see a link status of "down" you are either missing the cable or the port is not turned up. Obviously you will want to run this command on every network adapter you have to see which ones are cabled up.


Jim Hirschauer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top