Age | Commit message (Collapse) | Author |
|
To be able to set the test->outfile to a different file other than default
if using libiperf API.
Since logfile is now opened in iperf_parse_arguments() and this function
may not be used if running iperf using API, define a dedicated function
iperf_open_logfile() and move the opening of logfile into
iperf_run_client() and iperf_run_server() to make sure logfile will be
opened if iperf_parse_arguments() was not called.
|
|
Adds the `--bidir` flag to support simultaneous two-way tests.
Submitted by @LikHait. Fixes #201.
|
|
accelleran-iperf_time
|
|
There are lots of mixed tabs and spaces, most of them look OK if tabs are 8
characters wide, but this bit seems to have been written by someone whose editor
thinks they're 4 characters wide, so it looks all messed up.
|
|
|
|
(#682)
The user-visible symptom was messages of the following form on the
server:
iperf3: the client has unexpectedly closed the connection
This bug was introduced in #597 and was present in iperf 3.2 and 3.3.
Fixes #677.
|
|
* Attempt to quiet a warning with print(3) formatting. As a part of this, factor out PRIu64 support / compatibility (added in #664) into a header file and make it more portable by taking into account the size of a long integer. Based on email conversation with: @pprindeville.
* Follow-up to pull request #669, fixing compiler warnings on platforms that don't have HAVE_TCP_CONGESTION defined.
|
|
|
|
Ignore nonsensical TCP MSS when trying to compute the default UDP packet size. This fix seems to be primarily needed for Windows systems, but it's a good bit of sanity checking to do in any case.
|
|
Suggested by @pprindeville.
|
|
1. Make sure we have a valid TCP MSS on the path when comparing
the UDP block size.
2. Fix a redundant "warning".
This should fix a bug observed on Windows but not (so far) on any
UNIX-like platforms. Fixes #608.
|
|
This avoids a leak of file descriptors.
|
|
* Add configurable timeout for the setup of the control connection.
This is specified using the new --connect-timeout option, with an
integer parameter in ms. The iperf3 client will wait for this
amount of time for the setup of the control connection to the
server. If this option is not given, the OS default for TCP
connection setup is used. Specifying a smaller connection timeout
allows faster detection of a down / unresponsive iperf3 server.
The implementation uses a variation on the timeout_connect()
function from OpenBSD's netcat utility.
Fixes #216.
|
|
Stumbled on by: @daldoyle
|
|
* Dynamically determine an appropriate default UDP send size.
We use the TCP MSS for the control connection as the default UDP
sending length, if the --length parameter is not specified for a
UDP test. This computation replaces the former hard-coded 8K
default, which was way too large for non-jumbo-frame Ethernet
networks.
The concept for this solution was adapted from nuttcp. The
iperf3 implementation is pretty easy since we already were
getting the MSS for the control connection anyway (although we
needed to get it slightly earlier in the setup process to be
useful).
Towards issue #496.
While here, s/int/socklen_t/ in one place to fix a compile warning,
and bump a few copyright dates.
* Warn if doing a UDP test and the socket buffer isn't big enough.
This is surprisingly an issue on FreeBSD and macOS, where the MTU
over the loopback interface is actually larger than the default
UDP socket buffer size. In these cases, doing a UDP test over the
loopback interface (with the new UDP defaults) will fail unless a
smaller --length or a larger --window size is set explicitly.
Linux has larger UDP socket buffers by default (much larger than the
largest possible MTU), but even in the case that the socket buffers
are too small to hold an MTU-sized send, the kernel seems to do the
send correctly anyway.
Still working towards a good solution for issue #496.
* Further refinement on UDP buffer size settings.
If the default buffer size on a UDP test can't hold a packet,
then increase the buffer size to be large enough to hold one
packet payload. (If the buffer size was explicitly set, but too
small to hold a packet payload, then warn but don't change the
buffer size.)
Minor code refactoring to...factor out some common code into
a new iperf_udp_buffercheck() function.
Still working towards issue #496.
|
|
This does not seek to address all cygwin portability issues
just this specific compile-time conflict
See also #280 and #295.
See https://github.com/esnet/iperf/issues/280
|
|
|
|
First, realize that we've been setting the congestion control (CC)
algorithm unnecessarily; rather than doing it for all listening or
connecting sockets, do it just for those sockets that are being used
for TCP test streams.
Record the CC algorithm in use (this handles the case where a CC algorithm
hasn't been specified), and have the client and server exchange this
information.
Report the CC algorithms that were used (note that it's theoretically
possible for the two ends of the test to be using different algorithms,
if no algorithm was explicitly specified and the two end hosts have
different defaults, or if one side allows setting the CC algorithm and
the other doesn't).
Committing to a branch to make it easier to test this code on a
wider combination of systems.
|
|
|
|
The case where we should have been binding the client sockets to
ephemeral ports at a specific address for parallel tests was broken.
Fixes #239
Submitted by: @jfitzgibbon
|
|
Note that the license remains a 3-clause BSD license; the only
license changes were to add the name of the program and to add
some punctuation.
|
|
Fixes a warning on MacOS.
|
|
When running multiple parallel streams, the specified port number
is incremented for each successive stream.
Signed-off-by: Kevin Constantine <kevin.constantine@gmail.com>
|
|
kevinconstantine-master
|
|
--cport can be specified for udp connections
Signed-off-by: Kevin Constantine <kevin.constantine@gmail.com>
|
|
with system header <locale.h>.
This apparently fixes problems on an ARM build, but this was generally
broken anyway. It's slightly amazing this didn't cause problems before;
perhaps we never used <locale.h> before?
Addresses #203.
|
|
|
|
side sockets). This is reported to fix some oddities after a recent
change in this area.
Somewhat related to Issue #125.
Submitted by: @i2aaron
|
|
transfer.
Note that the sender can either be the client or the server depending
on whether --reverse is used.
This fixes some problems with UDP transfers getting severely confused
and (wrongly) complaining about packets arriving out of order.
Related to issue #125.
|
|
Originally submitted by: @i2aaron
|
|
Related to Issue #119.
|
|
This works for both client and server side (in the case of the server,
either for daemon or non-daemon mode).
Consistifies a few places that were using printf instead of iprintf.
Fixes Issue 119.
|
|
Slightly reworked version of a patch that was...
Submitted by: Susant Sahani <ssahani@redhat.com>
|
|
Mostly this change consists of adding FreeBSD-specific code to handle
this feature. The concepts and system calls are very similar to what's
already done for Linux. One difference is that on FreeBSD, the CPU
affinity mask is saved before -A processing and restored afterwards.
This causes a slight change to the function signatures for
iperf_setaffinity() and iperf_clearaffinity() (these functions
however are not documented as a part of the libiperf3 API).
Slightly improve some of the documentation for the -A command line
option, to hopefully stave off some of the questions about this
feature.
Mostly based on a submitted patch.
Issue: 128 (better error message for CPU affinity failure)
Submitted by: Susant Sahani <ssahani@redhat.com>
|
|
When the client process gets interrupted, both the client and server
dump out accumulated interval statistics, as well as a partial set of
summary statistics (basically each side dumps what it has, but without
the exchange of information that usually happens at the end of a
normal run).
If the server process gets interrupted, the server dumps out its
accumulated interval and summary statistics as above. The client does
this as well in the -R case, but exits with a "Broken pipe" in the non
-R case (this behavior was present all along; it was not introduced in
this change). More investigation will be needed to understand the
client behavior.
Bump copyright dates in a few places.
Issue: 132 (signal handler for API calls)
Discussed with: aaron@internet2.edu
|
|
In -R mode, the test consists of the server sending to the client
until the client tells it to stop by setting the test state to
TEST_END via the control socket. However once the client changes the
test state, it stopped reading the incoming test data from the server.
In many (but not all) scenarios this could result in the server
filling up its send window (thus blocking on writes) before the
TEST_END message arrived from the client. At this point the server
was hanging waiting for the client to drain its data connection(s),
and the client was waiting for the server to send a state change
message for EXCHANGE_RESULTS.
Bump copyright date while here.
This fix handles at least part of...
Issue: 129 (iperf3 hangs with -R and -Z flags)
|
|
|
|
To the extent possible, anyway - on the sender side,
only the packet counts are available.
Also a few minor bug fixes.
|
|
This lets us check timers every tenth second instead of every second,
so we can switch out of the more expensive select() mode even with
the default reporting interval of a second.
|
|
|
|
fdset, not into both sets.
|
|
|
|
|
|
|
|
|
|
having it there may cause the select to return immediately every
time. Which is bad, m'kay?
Also, changed the coding idiom used to keep track of the maximum fd
in the fd sets, to be clearer.
|
|
|
|
The error numbers sent for SERVER_ERROR state were declared
as ints, and therefore could be 32 or 64 bits depending on
architecture. I changed them to be explicitly 32 bits.
This should be the last of these, I've checked out at every network
read/write call and they look ok.
And bumped the version to 3.0-RC5.
|
|
|
|
and iperf_run_server, so that API users get it too. Also, call
iperf_errexit with an appropriate message, which in -J mode dumps
out any accumulated JSON data.
|