Operating System - HP-UX
1832877 Members
2711 Online
110048 Solutions
New Discussion

Performance numbers on lan0

 
SOLVED
Go to solution
John T. Mills
New Member

Performance numbers on lan0

I have a 10/100 Mbps intergrated NIC in my HP9000. I wanted to determine the raw number of bytes that are going across it at any given time.

'netstat -I lan0' will return incoming and outgoing packets on the interface, but how do I determine the bytes?

Thanks in advance,

John
5 REPLIES 5
Juan González
Trusted Contributor

Re: Performance numbers on lan0

Hi John,
you can get the Inbound Octets, Outbound Octets and other statistics with lanadmin.

Best regards
Juan

John T. Mills
New Member

Re: Performance numbers on lan0

Well perhaps I should clarify that I am looking for a command line answer. I understand I can enter:

# lanadmin
Enter command: lan
Enter command: display

Is there another way to get this result from a single command?

Thanks,

John
Sridhar Bhaskarla
Honored Contributor
Solution

Re: Performance numbers on lan0

Hi John,

As far as my knowledge goes, all the default commands show only the packets on the interface. Packets can be of variable sizes.

You can either problem SNMP data or install any other third party tools like ethereal to get a snapshot of the utilization.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Sridhar Bhaskarla
Honored Contributor

Re: Performance numbers on lan0

In fact Juan is correct. You can get octets from lanadmin command. It went out of my head completely. You can use the following to get a non-interactive output of lanadmin.

#(echo lan; echo ppa 2; echo display; echo ""; echo quit) |lanadmin > /tmp/lanadmin.out

You can grep octets from lanadmin.out.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Juan González
Trusted Contributor

Re: Performance numbers on lan0

To get with a single command:

lanadmin -g PPA|grep "^Inbound Octets"

where PPA is the number that follows lan:
lan0-->0
lan1-->1
..

Therefore, if you want to get graphics of this I would recommend you MRTG. With it you can get graphics over time of any SNMP variable (numeric of course) in html format.

Best regards,
Juan