[netperf-talk] 802.11g udp and tcp bandwidth test

Rick Jones rick.jones2 at hp.com
Mon Jul 11 09:57:50 PDT 2011


On 07/11/2011 03:21 AM, Max Ip wrote:
> Hi all,
>
> I have network connection of two laptops connected through wifi in
> Access Point mode with bandwidth 54Mbps (802.11g).
>
> Now, to test the throughput, I used the following commands:
>
> netperf -H 192.168.1.4 -t TCP_STREAM -l 10 -c
>
> This gave me a TCP throughput of 11.89 Mbps.
>
> netperf -H 192.168.1.4 -t UDP_STREAM -l 10 -c
>
> This gave me a UDP throughput of 22.5 Mbps.
>
> I think the UDP bandwidth is ok to have 22.5 Mbps (around half of
> 54Mbps for half duplex channel). However, how can TCP bandwidth be
> just 11.89 Mbps?
>
> Could anyone help me?

There can be any number of reasons.  Lost packets, flow control, small 
window size, you name it.

The netperf UDP_STREAM test simply blasts data as fast as the sending 
stack will permit.  UDP does not have flow control and netperf (unless 
you ./configure --enable-intervals and set the added options) does not 
add any.  So, it will simply blast through lost traffic, unlike a 
TCP_STREAM test.  TCP will try very hard to get data to the receiver, 
and have it presented to the receiving application in order.

BTW, there is no "back traffic" in a UDP_STREAM test, so unless there is 
something else communicating on your WiFi network, or other issues (eg 
losses, link-level retransmissions etc) being half-duplex shoudln't 
really matter - that or I'm clueless about WiFi (which is entirely 
possible :)

Also, with the UDP_STREAM test, you need to consider issues of IP 
fragmentation - UDP messages larger than the MTU.  The way IP 
fragmentation and reassembly works, all the fragments must get through. 
  If any one fragment is lost, the entire datagram is effectively lost. 
  Thus a given packet loss rate is amplified as a greater message loss 
rate when sending fragmented UDP/IP datagrams.

happy benchmarking,

rick jones
the attached it some generic(ish) boilerplate for you to consider.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: net_perf_list
URL: <http://www.netperf.org/pipermail/netperf-talk/attachments/20110711/92adeb19/attachment.ksh>


More information about the netperf-talk mailing list