[SunHELP] HME the speed and duplex

-Mark- sunhelp at sunhelp.org
Mon Apr 2 10:58:01 CDT 2001


--0-1953443376-986227081=:48253
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Here is the script that I wrote/use to check our hme
interfaces.  I you have others, just modify the
script.
This should be a good base and show what ndd commands
are used.

Mark

--- Kevin Stevens <Kevin_Stevens at Bigfoot.com> wrote:
> Use the ndd utility (can also set parameters).  Wade
> through man ndd; it does
> a lot of other things you may find useful as well.
> 
> KeS
> 
> ----- Original Message -----
> From: "Triyono" <triyono at RTMGlobal.com>
> To: "sunhelp" <sunhelp at sunhelp.org>
> Sent: Sunday, April 01, 2001 21:53
> Subject: [SunHELP] HME the speed and duplex
> 
> 
> > Hi All,
> > I have NIC 10/100 Mb/s. Ho do I know in Solaris
> that I got full or half
> > duplex and 10 or 100 Mb/s.
> >
> > Thanks
> >
> > -triyono-
> >
> 
> _______________________________________________
> SunHELP maillist  -  SunHELP at sunhelp.org
> http://www.sunhelp.org/mailman/listinfo/sunhelp


__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/?.refer=text
--0-1953443376-986227081=:48253
Content-Type: text/plain; name="lanscan.txt"
Content-Description: lanscan.txt
Content-Disposition: inline; filename="lanscan.txt"

# Version 1.1
# This script will scan hme network interface
# for Solaris system.
# SUNW,hme Fast-Ethernet device driver
 
 
# Main Line
HOST_=`cat /etc/nodename`
HME_=`cat /etc/path_to_inst | grep hme | nawk '{print $2}'`
 
for instance in ${HME_}
do
 
 ndd -set /dev/hme instance ${instance} >/dev/null
        echo "+-------------------------------+"
 
        if [ `ndd /dev/hme link_status` = 0 ];then
                echo "hme${instance} status is down";else
       echo "hme${instance} status is up"
  fi
 
  if [ `ndd /dev/hme link_speed` = 0 ];then
                echo "hme${instance} link speed 10 Mbps";else
        echo "hme${instance} link speed 100 Mbps"
  fi
 
  if [ `ndd /dev/hme link_mode` = 0 ];then
        echo "hme${instance} link mode Half-Duplex";else
   echo "hme${instance} link mode Full-Duplex"
  fi
 
  if [ `ndd /dev/hme adv_autoneg_cap` = 0 ];then
        echo "hme${instance} Auto-Negotiation-OFF";else
                echo "hme${instance} Auto-Negotiation-ON"
  fi
 
 
 done

--0-1953443376-986227081=:48253--



More information about the SunHELP mailing list