iperf icon indicating copy to clipboard operation
iperf copied to clipboard

Support parallel UDP streams under Windows and Cygwin

Open davidBar-On opened this issue 4 years ago • 2 comments

  • Version of iperf3 (or development branch, such as master or 3.1-STABLE) to which this pull request applies: 3.10

  • Issues fixed (if any): #472 / #1161

  • Brief description of code changes (suitable for use as a commit message):

Suggested change to allow UDP parallel streams under Windows (and Cygwin). The change is based on the approach suggested by @rossro, as described in this #472 comment.

The change adds an option to the Windows Server's -p parameter that defines the number of ports available starting with the defined port : -p <port>/[<num of ports]

E.g -p 5201/2 specifies that ports 5201 and 5202 can be used for the UDP streams.

UPDATE (16-Apr-2023):

Updated to be fully backward compatible, including between Windows and other OS (including rebase to 3.13). This is by adding a UDP_CONNECT_REPLY_NEXT_PORT from a Windows server, to indicate that a different port should be used for the next UDP stream. The only combination that does not work is a Windows Server with older client version when multi UDP streams are used. However, this did not work anyway (just the error condition is changed).

davidBar-On avatar Jun 13 '21 10:06 davidBar-On

If the merge conflicts are resolved, is there something preventing this from merging otherwise?

I would love to use iperf to test bidirectional udp on windows and this would allow for that, in theory.

BoySanic avatar Aug 28 '25 23:08 BoySanic

If the merge conflicts are resolved, is there something preventing this from merging otherwise?

I would love to use iperf to test bidirectional udp on windows and this would allow for that, in theory.

As Windows is not officially supported by iperf3, I don't know if and when the iperf3 team will merge this PR. In any case, I have rebased the changes to the latest iperf3 master branch (3.19.1+), including conflicts resolution, so you may build from this branch.

davidBar-On avatar Aug 29 '25 12:08 davidBar-On