4

I had to determine UDP performance over multi-hop network , I used MAC Air over gigabit ethernet ( Thunderbolt). As is customary, TCP was tested and the gig over link was saturated ~900mbps, but surprise when I test UDP it got capped off at 650mbps.

Now I connected two nodes (PC's ) directly without switch. Both the nodes indicated they were working at PHY rate 1000mbps

Node A < -------- > Node B

  1. Node A ( MAC Book) Node B ( MAC Air) --- UDP throughput was 650 mbps TCP 944

  2. Node A ( MAC Book) Node B ( Win 7) --- UDP throughput was 600 mbps TCP 900

Please note I only consider UDP throughput with (0-1% PL), I adjusted the bandwidth from -b {1000,900,650}, I achieve the sweetness of 1% PL at 650. It did not make any sense, how can TCP usurp UDP.

Then from 2nd choice I use UDP with 4 streams the UDP throughput improved to 944mbps.

My question(s) are :-

  1. I understand in TCP the streams will improve tolerance to 2% PL and it will saturate the links with individual stream contributing to saturation. What does iperf UDP streams do? I read the --help but it is not clear.

  2. In case of individual nodes what can I do on my Apple, such that it allocates more UDP buffer (if at all it is a buffer issue). The link is 1Gig , and forget the multihop, even when it has a direct link with the client ( where there is no link sharing , supposedly no reason for dropped packets, or huge latencies, should have been able to over subscribe the link)

enter image description here

8
  • "What does iperf UDP streams do.?" UDP is stateless and connectionless. See this question and the answers on Stack Overflow.
    – Ron Maupin
    Oct 31, 2016 at 20:39
  • What is mean is: iperf will run multiple UDP flows simultaneously: "iperf --client --udp --parallel 4 ..."
    – vk5tu
    Nov 1, 2016 at 2:48
  • Ron to convince myself the packets are UDP payloads i went to some extra lengths a) To verify that iperf is sending UDP , i looked into wireshark and the payload is actually UDP. b) I checked at the activity monitor on my MAC OS with 4 streams , and i have data received indicates 940mbps on 4 streams (0%PL) compared to 650mbps 1 stream (0%PL)However i still cannot wrap my head around stream in UDP if it is connection less it should have subscribed the link to 950Mbps (with 1s) , considering TCP was 950mbps. Should i trust iperf UDP with Streams and not working like an incarnation of TCP? Nov 1, 2016 at 17:57
  • UDP isn't a stream the way TCP is. UDP is used by streaming protocols, but that is above layer-4. At layer-4, TCP sends a stream, but UDP does not. iPerf can be sending a bunch of UDP datagrams, but there is no connection like TCP has. TCP has connections, and it streams in those connections; UDP is connectionless, and any connections or streams are handled by protocols above UDP.
    – Ron Maupin
    Nov 1, 2016 at 18:06
  • Ron correct me if i am wrong so when i transmit using iperf -c x.x.x.x -w2M -i1 -P4 -t100 -u it means that the layer 4 is not creating 4 logical connections to the receiver but rather a layer above it. But what in iperf is used as an application because the data sent in iperf is garbage ( just jumbled payload) , i am confused as to how iperf can take services of application layer. Nov 1, 2016 at 21:15

2 Answers 2

2

What does iperf UDP streams do

iperf will attempt to send UDP packets to reach the rate given in --bandwidth. If that parameter is missing, it will attempt to achieve the rate of the transmitting interface.

what can i do on my Apple

You can measure both computers' resource use, as there's a bottleneck. CPU is the most likely bottleneck, given that parallel transfers have superior performance. See the --single_udp parameter for a easy way to determine single core versus multicore performance.

Note that you've chosen really odd platforms. I've no idea what the per-packet overhead of what the MacBook Air's Thunderbolt-attached gigabit ethernet dongle might be compared with PCIe. So you are going to have to do a lot of the investigation of potential bottlenecks yourself.

1
  • i also think it might be a bottle neck but not the limitation on the link itself because the TCP throughput is 950mbps. But the reason i posted this is my fear that the UDP (with multiple streams ) is an incarnation of TCP. Nov 1, 2016 at 20:26
2

TCP uses SLOW START to maximize bandwidth and minimize lost packets, so it adapts to the slowest link in the chain by waiting for acks to come back. UDP leaves it to the application layer, and iperf doesn't wait for acks it just obeys the bandwidth you tell it to use with the --bandwidth option even if it overwhelms a link and causes substantial packet loss.

By the way, be careful with iperf. It is used in denial of service attacks. Attackers find a server, then tell a compromised cliet to request a huge UDP push. They got me on AWS 28TB @$.09/GB was about $2000 :(

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.