Operating System - HP-UX
1752780 Members
6580 Online
108789 Solutions
New Discussion юеВ

Re: Script to find details related to Networking - Duplex/Speed/AutoNegotiation

 
SOLVED
Go to solution
Kennedy G. Doss
Regular Advisor

Script to find details related to Networking - Duplex/Speed/AutoNegotiation

Fellow SAs:

Does any one have a script which kind of pulls details related to Duplex / Speed / Auto Negotiation / APA of the various LAN Cards on a servers? If yes, could you please point me to the link or share it with me?

Any input would be most appreciated.

Regards,
Kennedy Doss
4 REPLIES 4
Michael Steele_2
Honored Contributor
Solution

Re: Script to find details related to Networking - Duplex/Speed/AutoNegotiation

Hi

Netperf

http://www.netperf.org/

Put this in a script and adjust for throughput, or speed and duplex which also be in lanadmin:


For example:
# (echo "lan,ppa,0,display,quit" | lanadmin 2>/dev/null) | grep Octets
Inbound Octets = 969135997
Outbound Octets = 201604344

# (echo "lan,ppa,0,display,quit" | lanadmin 2>/dev/null) | grep -i -e speed -e duplex

Wait 90 seconds...

# (echo "lan,ppa,0,display,quit" | lanadmin 2>/dev/null) | grep Octets
Inbound Octets = 984739384
Outbound Octets = 223847387

delta_rx = 984739384 - 969135997 = 15603387
delta_tx = 223847387 - 201604344 = 22243043
interval = 90

rate_rx = delta_rx/interval = 15603387/90 = 173370.97 bytes/s
rate_tx = delta_tx/interval = 22243043/90 = 247144.92 bytes/s
Support Fatherhood - Stop Family Law
Bill Hassell
Honored Contributor

Re: Script to find details related to Networking - Duplex/Speed/AutoNegotiation

Here's a script to display current LAN card status including APA details. It is very useful on systems with a lot of LAN cards. The -f option specifies which field to sort.


Bill Hassell, sysadmin
Kennedy G. Doss
Regular Advisor

Re: Script to find details related to Networking - Duplex/Speed/AutoNegotiation

This is exactly what I was looking for. You've once again saved me a lot of time, Bill. Thanks a billion.
Kennedy G. Doss
Regular Advisor

Re: Script to find details related to Networking - Duplex/Speed/AutoNegotiation

The script which Bill Hassell sent was the one which I made use of for the sake of simplicity. The earlier solution works too giving me more information. Thanks to both of them.