Operating System - HP-UX
1832694 Members
3058 Online
110043 Solutions
New Discussion

Re: Finding NIC speed using dlpi

 
SOLVED
Go to solution
Rajesh Jangam
New Member

Finding NIC speed using dlpi

Hi,

I am trying to get the NIC speed on HP-UX.

I also required the MAC address - I could do
it programatically using dlpi.

Is there a way using dlpi to get the NIC speed?
Any alternate way will also do, provided, it is
programatic.

Thanks in Advance,
Rajesh
5 REPLIES 5
melvyn burnard
Honored Contributor

Re: Finding NIC speed using dlpi

posted in wrong forum, moved to correct forum
My house is the bank's, my money the wife's, But my opinions belong to me, not HP!
rick jones
Honored Contributor
Solution

Re: Finding NIC speed using dlpi

IIRC one of the fields of the statistics one can retrieve via DLPI encodes the bitrate of the interface.
there is no rest for the wicked yet the virtuous have no pillows
Rajesh Jangam
New Member

Re: Finding NIC speed using dlpi

Thanks for the pointer Rick.

I used the DL_GET_STATISTICS_REQ
to get the statistics of the nic.

Interpreted the resultant information with
DL_GET_STATISTICS_ACK as -

struct mib_ifEntry

It has a field - ifSpeed.
rick jones
Honored Contributor

Re: Finding NIC speed using dlpi

BTW, I think that may be only 32-bits, which is fine up to 1 gigabit links, but for a 10 gigabit link I'm not entirely certain what it would return :) Perhaps just a value of "10" :)
there is no rest for the wicked yet the virtuous have no pillows
Victor Fridyev
Honored Contributor

Re: Finding NIC speed using dlpi

Hi,

lanadmin -x NIC_ID
will give you the requested.

HTH
Entities are not to be multiplied beyond necessity - RTFM