TCPIP Utilities

Internet CS

Displaying connection statistics by using netstat

 

Please comment on this article here

 

You can use the netstat command to display protocol statistics and current TCP/IP connections. The netstat -a command displays all connections, and netstat -r displays the route table plus active connections. The netstat -e command displays Ethernet statistics, and netstat -s displays per-protocol statistics. If you use netstat -n, addresses and port numbers are not converted to names. The following shows sample output for netstat:

C:\>netstat -e
Interface Statistics

                       Received      Sent
Bytes                  3995837940    47224622
Unicast packets        120099        131015
Non-unicast packets    7579544       3823
Discards               0             0
Errors                 0             0
Unknown protocols      363054211

C:\>netstat -a

Active Connections

 Proto Local Address      Foreign Address       State
 TCP  CORP1:1572       172.16.48.10:nbsession   ESTABLISHED
 TCP  CORP1:1589       172.16.48.10:nbsession   ESTABLISHED
 TCP  CORP1:1606       172.16.105.245:nbsession ESTABLISHED
 TCP  CORP1:1632       172.16.48.213:nbsession  ESTABLISHED
 TCP  CORP1:1659       172.16.48.169:nbsession  ESTABLISHED
 TCP  CORP1:1714       172.16.48.203:nbsession  ESTABLISHED
 TCP  CORP1:1719       172.16.48.36:nbsession   ESTABLISHED
 TCP  CORP1:1241       172.16.48.101:nbsession  ESTABLISHED
 UDP  CORP1:1025       *:*
 UDP  CORP1:snmp       *:*
 UDP  CORP1:nbname     *:*
 UDP  CORP1:nbdatagram *:*
 UDP  CORP1:nbname     *:*
 UDP  CORP1:nbdatagram *:*
C:\>netstat -s
IP Statistics

 Packets Received             = 5378528
 Received Header Errors       = 738854
 Received Address Errors      = 23150
 Datagrams Forwarded          = 0
 Unknown Protocols Received   = 0
 Received Packets Discarded   = 0
 Received Packets Delivered   = 4616524
 Output Requests              = 132702
 Routing Discards             = 157
 Discarded Output Packets     = 0
 Output Packet No Route       = 0
 Reassembly Required          = 0
 Reassembly Successful             = 0
 Reassembly Failures               = 0
 Datagrams Successfully Fragmented = 0
 Datagrams Failing Fragmentation   = 0
 Fragments Created                 = 0

ICMP Statistics
                          Received  Sent
 Messages                 693       4
 Errors                   0         0
 Destination Unreachable  685       0
 Time Exceeded            0         0
 Parameter Problems       0         0
 Source Quenches          0         0
 Redirects                0         0
 Echoes                   4         0
 Echo Replies             0         4
 Timestamps               0         0
 Timestamp Replies        0         0
 Address Masks            0         0
 Address Mask Replies     0         0

TCP Statistics

 Active Opens                 = 597
 Passive Opens                = 135
 Failed Connection Attempts   = 107
 Reset Connections            = 91
 Current Connections          = 8
 Segments Received            = 106770
 Segments Sent                = 118431
 Segments Retransmitted       = 461
 
UDP Statistics

 Datagrams Received   = 4157136
 No Ports             = 351928
 Receive Errors       = 2
 Datagrams Sent       = 13809

 

 

 

eXTReMe Tracker

Links: