Viewing Link Statistics


Many times it is important to get an idea of the flow of network traffic within a MachTen system. The netstat command used with different parameters presents a detailed picture of packet flow and error conditions within MachTen systems. Details about netstat and it's parameters can be found in the netstat reference information.

Netstat -i

The netstat -i command shows the different configured networking interfaces within a system. It shows the number of received and transmitted packets and packets treated as errors. Netstat -i is valuable for showing that packets are attempting to flow across a specific interface.

usr@mtsys% netstat -i
Name Mtu Network Address Ipkts Ierrs Opkts Oerrs Coll
ie0 1500 192.83.246 scratch 214 0 86 0 0
lo0 1536 loopback localhost 0 0 0 0 0
usr@mtsys%

Netstat -r

The netstat -r command shows different routes within a MachTen system. It shows the destination address, thev gateway interface used to get to that address, whether the interface is up or down, the number of references to the interface, the number of packets routed across that interface and the name of interface.

usr@mtsys% netstat -r
Routing tables
Destination Gateway Flags Refs Use Interface

INET routing:
default 192.83.246.3 UG 0 0 ie0
localhost 127.0.0.1 UH 1 0 lo0
192.83.246 192.83.246.20 U 1 85 ie0
usr@mtsys%

Netstat -an

The netstat -an command prints statistics about different network sockets within a MachTen system. Showing statistics about connected local and remote internet and Unix sockets, any data queued for the socket pair, sockets waiting for remote requests to connect to them and Unix domain sockets.

Active Internet connections (including servers)
Proto Recv Send Local Address Foreign Address (state)
tcp 0 0 */37 */* LISTEN
tcp 0 0 */13 */* LISTEN
tcp 0 0 */110 */* LISTEN
tcp 0 0 */4002 */* LISTEN
tcp 0 0 */540 */* LISTEN
tcp 0 0 */512 */* LISTEN
tcp 0 0 */513 */* LISTEN
tcp 0 0 */514 */* LISTEN
tcp 0 0 */23 */* LISTEN
tcp 0 0 */21 */* LISTEN
udp 0 0 */37 */*
udp 0 0 */9 */*
udp 0 0 */7 */*
udp 0 0 */518 */*
udp 0 0 */514 */*
Active UNIX domain sockets
Address Type Recv-Q Send-Q Inode Conn Refs Nextref Addr
12d3400 dgram 0 0 10188e8 0 0 0 /dev/log

Netstat -s

The netstat -s command shows various statistics about the protocol software within a MachTen system. Especially intersting are the IP statistics showing packets discarded due to checksum error, and the TCP statistics showing retransmissions and duplicate packet reception. Growing number of checksum errors indicated that data coming across an interface has been damaged indicating some sort kind of link problem. Growing number of retransmissions indicate that a link is dropping packets somewhere along the route to its destination. Growing numbers of duplicate packets indicate that a transmitter is resending packets multiple times that are being discarded along the route to the local MachTen system or are being delayed along the path to the local MachTen system.

ip:
170 total packets received
0 bad header checksums
0 with size smaller than minimum
0 with data size < data length
0 with header length < data size
0 with data length < header length
0 fragments received
0 fragments dropped (dup or out of space)
0 fragments dropped after timeout
0 packets forwarded
64 packets not forwardable
0 redirects sent
icmp:
91 calls to icmp_error
0 errors not generated 'cuz old message was icmp
Output histogram:
destination unreachable: 91
0 messages with bad code fields
0 messages < minimum length
0 bad checksums
0 messages with bad length
0 message responses generated
tcp:
0 packets sent
0 data packets (0 bytes)
0 data packets (0 bytes) retransmitted
0 ack-only packets (0 delayed)
0 URG only packets
0 window probe packets
0 window update packets
0 control packets
0 packets received
0 acks (for 0 bytes)
0 duplicate acks
0 acks for unsent data
0 packets (0 bytes) received in-sequence
0 completely duplicate packets (0 bytes)
0 packets with some dup. data (0 bytes duped)
0 out-of-order packets (0 bytes)
0 packets (0 bytes) of data after window
0 window probes
0 window update packets
0 packets received after close
0 discarded for bad checksums
0 discarded for bad header offset fields
0 discarded because packet too short
0 connection requests
0 connection accepts
0 connections established (including accepts)
0 connections closed (including 0 drops)
0 embryonic connections dropped
0 segments updated rtt (of 0 attempts)
0 retransmit timeouts
0 connections dropped by rexmit timeout
0 persist timeouts
0 keepalive timeouts
0 keepalive probes sent
0 connections dropped by keepalive
udp:
0 incomplete headers
0 bad data length fields
0 bad checksums


| Tenon Home | Products | Order | Contact Us | About Tenon | Register | Tech Support | Resources | Press Room | Mailing Lists |

Powered By iTools

Copyright©2009 Tenon Intersystems, 232 Anacapa Street, Santa Barbara, CA 93101. All rights reserved.
Questions about our website - Contact: webmaster@tenon.com.