Practical Guide to AIX - network
Network
netstat -i shows statistic of all defined network interfaces (the * at the name means currently inactive)
if Oerrs greater than 1% of Opkts -> xmt_que_size (send queue size) should be increased
if Ierrs greater than 1% of Ipkts -> check for a lack of memory (netstat -m)
netstat -m network memory statistics (failed and delayed columns should be checked)
netstat -v show many statistical informatoins about interfaces (look for collisions, transmit errors)
netstat -ss shows non-zero values of netstat (it is a non documented patameter)
netstat -D shows input and output statistcs at each layer
netstat -I en0 2 shows traffic across that interface in 2 seconds intervals
netstat -a shows information about sockets (LISTEN, ESTABLISHED,...)
netpmon monitors and reports statstics on network
no -a shows network options
no -a | grep space shows receive and sendspace sizes (it can happen that those are not enough large)
no -o thewall shows the amount of real memory (in kb) that can be used for the network memory pool on a machine
Checking netw. protocol statistics:
1. netstat -p ip
first look at IP statistics - all other protocols are on top of it
(check: bad header checksum, fragments dropped - this indicates a network which is corrupting packets or device driver queue not large enough)
2. netstat -p tcp
packets sent and retransmitted: if retransmitted is over 15% of total packets sent, then TCP experiencing timeouts (before ACK arrives)
-bottleneck on the receiving node
-or general network problems can cause TCP retransmissions (too much network traffic)
packets received/completely duplicate packets: if timeout occurs on sending node before ACK arrives from receiving node, it will
retransmit the packet. IF all the packets are received, duplicate packets occur, this should be less then 15% of packets received:
-bottleneck on the receiving node
-too much network traffic
3. netstat -p udp
we want to avoid any dropped packets in UDP protocol
dropped due to no socket:
-UDP socket receive buffer on the local machine too small
-the application not reading the data fast enough
The larger the MTU, the better throughput one can get, when sending large amount of data.
------------------------
Testing network speed with FTP:
test by connecting via FTP to another server, and sending a block of data directly to /dev/null.
(This will stop the server from writing it to disk, and therefore give you pure network speeds:)
1. Connect to a server via FTP from another server.
2. Enter: put "|dd if=/dev/zero bs=3M count=1000" /dev/null
3. Monitor the speeds with your favorite monitoring solution topas, top etc.
Testing network speed with IPERF:
Iperf is an RPM tool and it can be downloaded from perzl.org (http://www.perzl.org/aix/index.php?n=Main.iperf).
It has to be installed at client and server side, after that from client it makes a connection to server at port 5001 and checks bandwidth.
1. rpm -ivh iperf-2.0.5-1.aix5.1.ppc.rpm <--install rpm package (on client and at server as well)
2. on server: iperf -s <--at server side, it will listen on port 5001
3. on client: iperf -c <server ip> -t 60 -P 8 <--on client it will make 8 connections to given server for 60 sec
------------------------------------------------------------
Client connecting to bb_lpar, TCP port 5001
TCP window size: 128 KByte (default)
------------------------------------------------------------
[ ID] Interval Transfer Bandwidth
[ 9] 0.0-60.0 sec 31.7 GBytes 4.54 Gbits/sec
[ 7] 0.0-60.0 sec 31.7 GBytes 4.54 Gbits/sec
[ 10] 0.0-60.0 sec 1.66 GBytes 238 Mbits/sec
[ 3] 0.0-60.0 sec 33.6 GBytes 4.81 Gbits/sec
[ 4] 0.0-60.0 sec 33.6 GBytes 4.81 Gbits/sec
[ 5] 0.0-60.0 sec 1.66 GBytes 237 Mbits/sec
[ 8] 0.0-60.0 sec 1.65 GBytes 237 Mbits/sec
[ 6] 0.0-60.0 sec 1.66 GBytes 237 Mbits/sec
[SUM] 0.0-60.0 sec 137 GBytes 19.7 Gbits/sec
------------------------
On adapters with 64 KB or larger MTUs, TCP streaming performance can be degraded if the receive buffer is 64 KB or less.
...you are looking for a high level of error packets, retransmissions, or dropped packet transmission, all of which indicate that the network is busy...but increasing MTU can increase network performance.
------------------------