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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Check interface speed

Status
Not open for further replies.

babeo

Technical User
Mar 30, 2000
398
CA
Hello,
I want to check what is the speed of each interface of my boxes. Could someone give me a hand please?
Thanks
 
eg. if you have two hme interfaces it works like that:

ndd -set instance 0
ndd -get /dev/hme link_speed
0 = 10 MBit/s
1 = 100 MBit/s
ndd -get /dev/hme link_mode
0 = halfduplex
1 = fullduplex
ndd -get /dev/hme link_status
0 = no link
1 = link is established

ndd -set instance 1
ndd -get /dev/hme link_speed
ndd -get /dev/hme link_mode
ndd -get /dev/hme link_status

if you have other NICs just replace hme by eri, ge, ...



Best Regards, Franz
--
Solaris System Manager from Munich, Germany
I used to work for Sun Microsystems Support (EMEA) for 5 years
 
Hi Franz,
Looks like I have some error messages:
- ndd /dev/ce1 link_speed
"couldn't push module 'ce1', No such device or address"
- ndd /dev/qfe0 link_speed
"couldn't push module 'qfe0', No such device or address"
- ndd -get /dev/hme0 link_speed
couldn't push module 'hme0', No such device or address

What are the commands "ndd -set instance 0" and "ndd -set instance 1" doing?,
and should I run the 1st set of "ndd -set instance 0" before I run the "ndd -set instance 1" set of commands ?

Thanks
 
You can't use the indexed interface (/dev/hme0 /dev/ce1), only the driver name (/dev/hme /dev/ce). You have to select the interface via the instance variable ("ndd -set /dev/hme instance 1" for hme1, "ndd -set /dev/ce instance 2" for ce2). All subsequent ndd commands to the same driver go to the selected instance.
 
Thanks,
I understand now.
However, I still have problems here !
From my server configuration:
MyServer$ ifconfig -a
lo0: flags=xxxxxxxxxxxxxxxxx
ce1: flags=xxxxxxxxxxxxxxxxx
qfe0: flags=xxxxxxxxxxxxxxxx

MyServer$ ndd -set /dev/qfe0 instance 0
couldn't push module 'qfe0', No such device or address

-ndd -set /dev/ce1 instance 1
couldn't push module 'ce1', No such device or address

Could you help again please?
Thanks
 
Ah, I forgot to post:
I try with this command, and it seems working, so how do I figure out when to use what command?

MyServer$ netstat -k ce1 |grep link

Thanks
 
I have other questions:
this is the result from 3 cards:

$ netstat -k qfe0|grep link
toolong_errors 0 macrcv_errors 0 link_up 1 link_duplex 1

$ netstat -k hme0|grep link
link_duplex 0 inits 9 rxinits 0 txinits 0 dmarh_inits 0
dmaxh_inits 0 link_down_cnt 0 phy_failures 0 xcvr_vendor 24605 asic_rev 193 link_up 1

# netstat -k ce1 |grep link
lp_cap_asmpause 0 lp_cap_pause 0 link_T4 0 link_speed 100 link_duplex 2 link_asmpause 0 link_pause 0 link_up 1 mac_mtu 1522

I see many descriptions such as "link_up", "link_speed", which one is telling me the "auto" setup and which one is manually set to "100MBits/s" ?
Thanks for your help.
 
The ndd issue: use "ndd -set /dev/ce instance 1" and NOT "ndd -dev /dev/ce1 instance 1", again: it's "ce", not "ce1".
 
Thanks huebs,
I think you have typo in the command (I repost your post: "The ndd issue: use "ndd -set /dev/ce instance 1" and NOT "ndd -dev /dev/ce1 instance 1", again: it's "ce", not "ce1".).

I use "ndd -set /dev/ce1 instance 1", but not
"ndd -dev[/red] /dev/ce1 instance 1".

Infact, I still have error when using without a number.

- ndd -set /dev/ce instance 1
couldn't push module 'ce', No such device or address

Thanks anyway, it works for me with "netstat" command.
 
babeo, which OS Version are you running on which Hardware?
the ndd commands should work, this is what Sun recommends...!

Best Regards, Franz
--
Solaris System Manager from Munich, Germany
I used to work for Sun Microsystems Support (EMEA) for 5 years
 
Hi Franz,
- Sun OS 5.8
- Hardwares: SunFire 480R, SunFire 880, Sun-Ultra80, and Sun Ultra 60.

By the way, how come your command is different with huebs' command, are they combined into 1 instead of exe 2 commands?

Your: ndd -set instance 1
ndd -get /dev/hme link_speed

Huebs: ndd -set /dev/hme instance 1

Thanks for your explanation.
 
hmm, I just forgot the /dev/hme in "ndd -set /dev/hme instance 1" :)

Best Regards, Franz
--
Solaris System Manager from Munich, Germany
I used to work for Sun Microsystems Support (EMEA) for 5 years
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top