Commit Graph

537 Commits

Author SHA1 Message Date
Jef Poskanzer
bdf5335c2b Added burst mode. 2013-12-17 16:12:24 -08:00
Jef Poskanzer
62bfa88ceb Added -C / --linux-congestion.
Also a few other bugfixes I ran across.
2013-12-13 19:57:52 -08:00
Jef Poskanzer
adec7fe48b Re-order one line to clarify code. 2013-12-12 12:09:42 -08:00
Jef Poskanzer
950f6c8f59 Better error checking in net.c 2013-12-12 12:07:17 -08:00
Jef Poskanzer
fdcbd49578 Check return from tmr_create in timer test. 2013-12-12 12:04:11 -08:00
Bruce A. Mah
0193ee1881 Commit a file addition I forgot in 2ad1efdb977e. 2013-12-12 09:32:15 -08:00
Bruce A. Mah
d04c7bd0a4 Support setting the IPv6 flow label on Linux systems (only).
This functionality uses some setsockopt(2) calls that unfortunately
don't seem to have an analog on other platforms.

Slightly tweaked version of a patch that was...

Submitted by:	ssahani@redhat.com
Issue:		40 (Option for setting Flow Label field in IPv6
		header)
2013-12-12 09:21:36 -08:00
Jef Poskanzer
c8a0a2229d Added a check for malloc fail.
Eventually we need to add a whole bunch more of these.
2013-12-12 08:15:15 -08:00
Jef Poskanzer
b70c54055f Fixed t_units.c so that 'make check' once again works. 2013-12-09 17:52:59 -08:00
Jef Poskanzer
c06bc78c65 Fixed initialization issue.
It was causing the server side to mess up after the first test.
2013-12-05 12:00:46 -08:00
Jef Poskanzer
a4c1383a77 Fixed bug where -R mode selected on a closed file.
Also added a debugging routine to dump an fd_set.
2013-12-05 08:49:27 -08:00
Jef Poskanzer
95360b2046 Show UDP stats in interval reports.
To the extent possible, anyway - on the sender side,
only the packet counts are available.

Also a few minor bug fixes.
2013-12-04 09:16:37 -08:00
Jef Poskanzer
e41823c46b Pushing out merge of inadvertent branch. 2013-12-02 09:55:48 -08:00
Bruce A. Mah
adbc1f4860 Document the recently-added -D / --daemon flag from changeset
4a9b814c16e6.
2013-12-02 09:38:13 -08:00
Jef Poskanzer
ba123d5c1e Use setitimer() instead of alarm().
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.
2013-11-29 08:58:51 -08:00
Bruce A. Mah
fe4a13ab4d Support daemonizing with -D flag.
Possible related work still under consideration:

o Use syslog in daemon mode for output that would normally go to
  stdout / stderr.

o Write a PID file.

This is basically the gist of Issue 105.
2013-11-26 15:40:19 -08:00
Jef Poskanzer
ace30a641e Fix server-side timers. 2013-11-26 15:14:07 -08:00
Jef Poskanzer
056361fc5d Show user/system CPU usage as well as total. 2013-11-26 14:47:15 -08:00
Jef Poskanzer
ba7b91d26e Changed bug report email to google code link.
Also bumped package id from 3.0a4 to 3.0a5.

This changeset consists of a one-line edit to configure.ac, plus
about fifty kilolines of diffs to a bunch of other config files
generated by bootstrap.sh.
2013-11-26 10:07:32 -08:00
Jef Poskanzer
96feeac5a4 Performance improvement - only put socket fd's into the appropriate
fdset, not into both sets.
2013-11-25 11:13:28 -08:00
Jef Poskanzer
979405373d When receiving a disk file with the -F flag, do an fsync() after each write(). 2013-11-25 09:57:50 -08:00
Jef Poskanzer
7bcbb1f653 Performance improvements. 2013-11-15 09:54:21 -08:00
Jef Poskanzer
37ba3f73dd Simplified output formatting. 2013-11-12 08:58:00 -08:00
Jef Poskanzer
b47e9f6a66 Couple of improvements to the report format. 2013-11-11 12:16:38 -08:00
Jef Poskanzer
a98b10bf91 Get rid of compiler warning. 2013-11-11 11:38:52 -08:00
Jef Poskanzer
d1405717cd Redid the CPU Utilization report so it shows sender/receiver as
well as local/remote.
2013-11-11 11:37:07 -08:00
Jef Poskanzer
558c9b8013 Moved a bunch more output strings to locale.[hc]. 2013-11-11 11:18:46 -08:00
Jef Poskanzer
5348f76aa9 Typo in test code. 2013-11-09 14:26:01 -08:00
Jef Poskanzer
32ebd649b3 Fixed some memory & fd leaks in error cases of various network setup
routines.
2013-11-09 14:23:36 -08:00
Jef Poskanzer
0e60ef1f9c Get rid of some compiler warnings about iprintf. 2013-11-08 21:19:59 -08:00
Jef Poskanzer
d38ab4c8df Added the -T / --title flag. 2013-11-08 20:31:19 -08:00
Jef Poskanzer
243c974f23 Note -i's default in the man page. 2013-11-08 16:13:40 -08:00
Jef Poskanzer
565366424b Changed default for -i from 0 to 1. 2013-11-08 16:12:26 -08:00
Jef Poskanzer
082cbb0ee6 The ctrl_sck does not need to be in the select write_set, and indeed
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.
2013-11-08 15:59:17 -08:00
Jef Poskanzer
e35f2035d5 Added a cast to avoid a compiler warning. 2013-11-07 08:20:04 -08:00
Jef Poskanzer
d2b9eb1a87 Another potentially protocol-breaking but necessary change.
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.
2013-11-07 08:14:45 -08:00
Jef Poskanzer
8115b2a26e Grammar correction in error message. 2013-11-06 15:24:47 -08:00
Jef Poskanzer
4e2ef5070b More sizeof changes.
A couple more sizeof issues found and fixed.  One of them is
actually another protocol change, but due to a fortuitous accident
it should remain compatible with older versions.

Detailed explanation: When a client attempts to connect to a server that
is already busy, the server is supposed to return ACCESS_DENIED as a
state value.  It was doing so, but was writing it as an int, even though
state values are supposed to be signed chars.  The client read the value
correctly as a signed char, getting one byte and throwing away the rest.
So why did this ever work?  Because ACCESS_DENIED is the value -1, and
any byte of an int -1 equals a signed char -1.  If ACCESS_DENIED had been
any other value, this would have been an opvious bug and would have long
since been fixed.  As is, it stuck around working by accident until now.
2013-11-06 11:05:46 -08:00
Jef Poskanzer
2944aaa05b State is signed char.
test->state is an explicitly signed char, so the two routines that
manipulate it must use explicitly signed chars too.

One could argue that the two negative state values should have been
positive like the rest, but changing them now would be a protocol change.
2013-11-06 10:33:26 -08:00
Jef Poskanzer
3651fa29e2 Bump version.
On further reflection, last night's seemingly trivial change to
the JSON sending/receiving routines is actually a protocol change,
on some machines, and therefore merits a version number change.
2013-11-06 09:42:54 -08:00
Jef Poskanzer
ddb503b5a3 The JSON length field should be explicitly 32 bits, not just "int",
for better interoperation.
2013-11-05 21:50:29 -08:00
Jef Poskanzer
9393606f5b Changed -O default from 1 to 0. 2013-11-03 14:22:37 -08:00
Jef Poskanzer
578a1961cf Bump version to 3.0-RC3. 2013-11-01 14:01:20 -07:00
Jef Poskanzer
38917b1f3f Run -i interval timers on the server as well as the client. 2013-11-01 13:59:33 -07:00
Jef Poskanzer
9019e92411 Bump version to RC2. 2013-10-29 15:05:05 -07:00
Jef Poskanzer
afe6222a89 Move termination signal handing from main into iperf_run_client
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.
2013-10-29 15:03:17 -07:00
Jef Poskanzer
7639c1a631 Bump version to RC1. 2013-10-28 17:14:25 -07:00
Jef Poskanzer
69376ec7ed Fix retransmit accounting so it works right with the --omit flag. 2013-10-28 17:13:30 -07:00
Jef Poskanzer
8a7e01eb8f Implement -A flag to set CPU affinity. 2013-10-25 17:00:52 -07:00
Jef Poskanzer
a953f5aa2c Re-do of how --omit works. 2013-10-24 14:08:04 -07:00
Jef Poskanzer
ea5d93b241 Always send omit client->server, otherwise omit==0 doesn't work. 2013-10-22 13:55:56 -07:00
Jef Poskanzer
965d8d7688 Added a summary line to the final report for the -F option. 2013-10-21 16:15:27 -07:00
Jef Poskanzer
e32a7bcd77 Added the -F / --file flag, to use a specified file instead
of random data for sending, and to save the data in the file
on receiving.
2013-10-19 07:43:38 -07:00
Jef Poskanzer
36662029e5 Added a timestamp in verbose and JSON output. 2013-09-14 08:59:50 -07:00
Jef Poskanzer
66ee0e2084 Got rid of the -d/--debug flag, it was not being used for anything. 2013-09-14 08:36:11 -07:00
Jef Poskanzer
cc2376c1e3 Bump version & date. 2013-09-14 08:33:17 -07:00
Jef Poskanzer
9e5f6f57f4 Add note in man page about the -w flag getting transmitted to the server. 2013-09-14 08:31:06 -07:00
Jef Poskanzer
f8bd11af23 Ran across a little error in some code that is currently
commented out. Worth fixing anyway.
2013-09-12 11:01:48 -07:00
Jef Poskanzer
65b2261d4c Slight enhancement to the logic for switching to SIGALRM timing mode. 2013-08-29 17:43:20 -07:00
Jef Poskanzer
8bdc8fffcf Fix bug in reverse mode. 2013-08-29 11:38:20 -07:00
Jef Poskanzer
78a711169e Crash fix from Aaron Brown. 2013-08-19 12:29:35 -07:00
Jef Poskanzer
5c01581b32 Detect that the system doesn't support IPv6 and try falling back to IPv4. 2013-08-19 10:02:01 -07:00
Jef Poskanzer
019434022c test->state needs to be explicitly signed char to accomodate a couple
of error states which are negative.  On most systems this doesn't
matter because char is signed, but on ARM CPUs char is unsigned.
2013-08-16 13:19:42 -07:00
Jef Poskanzer
cb6347fba9 Fix for issue 79, bad results when using the API. 2013-08-10 09:12:07 -07:00
Jef Poskanzer
d611f13e18 Fix incorrect default bandwidth limit when using the API instead
of the command line.
2013-07-12 19:56:49 -07:00
Andy Lake
861c06d862 Add queue.h to Makefile so will be included in package generated by 'make dist' 2013-07-11 14:07:41 -04:00
Jef Poskanzer
ba51358f7c Added API routines to get/set the verbose flag. 2013-07-10 15:12:51 -07:00
Jef Poskanzer
5789260432 Changed the -I / --ignore flag to -O / --omit, so that we can use the
same flag in bwctl.
2013-07-05 13:52:19 -07:00
Jef Poskanzer
26e392e175 Oops, left out the --version4 long opt. 2013-07-04 18:06:29 -07:00
Jef Poskanzer
c969359995 Added -I flag to ignore an initial period of data transfer,
defaulting to one second.
2013-07-03 12:01:57 -07:00
Jef Poskanzer
434e786fd0 More descriptive variable names for the throttling code. 2013-06-25 15:05:37 -07:00
Jef Poskanzer
647d3b95a8 New implementation of the -b bandwidth limit flag, that applies to
TCP as well as UDP.
2013-06-24 07:14:14 -07:00
Jef Poskanzer
cf06ba653a Server now exits after five consecutive errors. 2013-06-07 15:28:05 -07:00
Jef Poskanzer
3433c4d2c1 Better ifdefs for sendfile on OS/X. 2013-06-07 08:41:38 -07:00
Jef Poskanzer
c39c4f503f Added an ifdef for Mac OS/X version, to better protect the sendfile code. 2013-06-07 08:16:24 -07:00
Jef Poskanzer
5ec1d758f1 Raise maximum TCP buffer size to 512 MB. 2013-06-04 16:38:49 -07:00
Jef Poskanzer
481853ae5a Convert IPv4-mapped IPv6 address strings into regular old IPv4 format. 2013-06-04 00:11:41 -07:00
Jef Poskanzer
c687db9da2 Storing the known-to-not-work Flow Label code, just to save it.
The user-visible parts are commented out or return a "not implemented
yet" error message.  The other parts are harmless.

We'll come back to this once we figure out how exactly one sets
the Flow Label.
2013-06-03 13:12:43 -07:00
Jef Poskanzer
912bf5784f Add message emphasizing when we're doing reverse mode. 2013-05-31 10:36:12 -07:00
Jef Poskanzer
69bdbfd36d Handle retransmits correctly in reverse mode. 2013-05-29 15:18:18 -07:00
Jef Poskanzer
2c042fd469 Simplify multiple client/server forward/reverse checks into
a single sender boolean.
2013-05-29 12:32:42 -07:00
Jef Poskanzer
aa0e8fd5ac Remove temp file. 2013-05-25 07:22:11 -07:00
Jef Poskanzer
d95da48aee Bytes == 0 is no longer notable; bytes < 0 remains so. 2013-05-08 18:45:25 -07:00
Brian Tierney
854088329a remove "NLANR" tag 2013-05-08 14:53:31 -07:00
Jef Poskanzer
e321855d26 getopt_long returns int, not char. 2013-05-06 09:41:35 -07:00
Jef Poskanzer
12d474e2b4 A couple other places that used struct sockaddr_in when they should
have used struct sockaddr_storage - fixed now.
2013-05-02 15:28:30 -07:00
Jef Poskanzer
111645ed0f Fix UDP for IPv6 and dual-stack. 2013-05-02 15:18:07 -07:00
Jef Poskanzer
a27f6534b5 Added second concurrency model based on SIGALRM. 2013-04-09 11:42:30 -07:00
Jef Poskanzer
a6b3f26be1 Dual-stack operation - IPv4 and IP46 in the same server.
Also added -4 flag to force IPv4.
2013-03-29 17:49:27 -07:00
Jon M. Dugan
495aeb6ba7 bump date to current date 2013-03-28 12:02:39 -05:00
Jef Poskanzer
c50556ff4f Renamed burst mode to multisend mode, because there's an nuttcp feature
we want to add someday that is also called burst mode.
2013-03-13 09:41:02 -07:00
Jef Poskanzer
0f53b154a3 Improved setnonblocking() to set the flag on or off instead of just on. 2013-03-12 13:05:50 -07:00
Jef Poskanzer
65db384358 Polishing up the iperf3.1 man page. 2013-03-12 12:57:19 -07:00
Jef Poskanzer
3e58754281 Added library man page and examples subdir. 2013-03-11 22:03:36 -07:00
Jef Poskanzer
e96ab74093 Move the JSON initialization/finalization insode the API. 2013-03-08 20:56:52 -08:00
Jef Poskanzer
a5621dd908 Added zerocopy stuff to the API, so that bwctl can use it. 2013-03-06 07:46:28 -08:00
Jef Poskanzer
c57e9f2494 Slight change to net.c routines to better handle writes/sendfiles
to a full socket.
2013-03-04 16:11:03 -08:00
Jef Poskanzer
987b432316 A bunch of changes mixed together in this commit, but the significant
one is the new -Z flag.

- Fixed potential bug in net.c's Nread and Nwrite routines.  If they
had ever needed to loop they would have read/written the wrong address,
due to incorrect pointer arithmetic - sizeof(void) is not 1.  Fix
was to change the type of the buffer pointer to char*, which also
meant adding casts to some callers.

- Better checking for conflicts between command-line flags - now they
should no longer be order-dependent.

- Added a new -Z / --zerocopy flag, to use a "zero copy" method of
sending data, such as sendfile(2) instead of the usual write(2).

- Renumbered error enum to make inserting new ones easier.
2013-03-04 15:55:16 -08:00
Jef Poskanzer
358985eb58 Page-align the read/write buffer. Unclear if this helps, but
it certainly doesn't hurt.
2013-03-01 09:41:33 -08:00
Jef Poskanzer
0da578e79f Improved version of setnonblocking() - still not used. 2013-02-28 11:26:51 -08:00
Jef Poskanzer
6ae6111b27 Show correct error on connect() failure. 2013-02-27 14:35:23 -08:00
Jef Poskanzer
1133dd0b6c Fix long help message to show theactual default values from the .h file.
Correct the default test duration to ten seconds.
2013-02-27 14:22:44 -08:00
Jef Poskanzer
50a45ea47e Add get/set json_output to the API. 2013-02-26 15:54:29 -08:00
Jef Poskanzer
43929b3698 Added "burst mode" to send a bunch of packets in a row without
intervening select() calls.  This increases performance quite a bit.
2013-02-22 15:54:05 -08:00
Jef Poskanzer
231c56296e Comment out the "__attribute__((hot))" declarations because they cause
compiler warnings on older systems.  They probably didn't help
performance anyway. They'll remain in the source as markers.
2013-02-18 14:56:37 -08:00
Jef Poskanzer
3a34e7c11b With the define corrected to long-long, no longer need an explicit cast
in the tmr_create calls.
2013-02-18 10:30:21 -08:00
Jef Poskanzer
e232c5d16e Couple of defines that should be long-longs. 2013-02-18 10:28:17 -08:00
Jef Poskanzer
037c0c2367 Handle timers longer than 2147 seconds (2^31 microseconds). 2013-02-18 09:06:50 -08:00
Jef Poskanzer
ba55284d44 Added some "hot" attributes to mark a few routines that deserve
extra optimization.  Most likely this has no effect.
2013-02-18 07:33:36 -08:00
Jef Poskanzer
63a0b8d5df Branch merge. 2013-02-18 07:21:59 -08:00
Jef Poskanzer
fbaa2467a6 Change the meaning of the combination of -n and -P flags.
Previously, if you used -n to specify a test sending a specified number
of bytes and -P to send multiple streams in parallel, iperf3 would send
that many bytes on each stream.  With this change it just sends the
specified total number of bytes regardless of how many streams are used.
2013-02-18 07:19:59 -08:00
Jef Poskanzer
a5122e8951 Fix a couple problems noted by the C++ compiler. 2013-02-15 09:10:56 -08:00
Jef Poskanzer
96609aecad Makefile tweak to get iperf3_profile to actual generate profiles. 2013-02-12 11:40:16 -08:00
Jef Poskanzer
2724cb3139 Don't need -lm in Makefile any more. 2013-02-11 22:04:52 -08:00
Jef Poskanzer
f19a68d53a Oops, left out the important line from the error routine. 2013-02-07 17:54:52 -08:00
Jef Poskanzer
7ea98727a8 Initialize a couple variables to NULL to get rid of bogus warnings. 2013-02-07 13:39:33 -08:00
Jef Poskanzer
079579187a Portability fix for cJSON. 2013-02-07 13:34:53 -08:00
Jef Poskanzer
eb0206e686 Better handling of non-exit errors in JSON.
Also converted one more error to the unified call.
2013-02-07 13:30:58 -08:00
Jef Poskanzer
bf501899e7 Added fflush to JSON output. 2013-02-07 12:37:10 -08:00
Jef Poskanzer
b5e0751f59 (Mostly) switched error reporting to a single routine that handles JSON mode. 2013-02-07 12:35:17 -08:00
Jef Poskanzer
cda2ce2a7e Fixed cjson.c to no longer require -lm. 2013-02-05 21:18:47 -08:00
Jef Poskanzer
5a561d9d40 Get rid of commented-out obsolete code. If it's needed it's in the
revision history.
2013-02-05 15:38:45 -08:00
Jef Poskanzer
9bfb54c0cc Add -J flag to produce JSON output instead. 2013-02-01 11:42:35 -08:00
Jef Poskanzer
17666b94d9 Updated the man page and help string so they correspond with the code.
This entailed some re-ordering, so the diff is large.
2013-01-28 18:14:34 -08:00
Jef Poskanzer
0569f7d192 Also change iperf.1 to iperf3.1 in the makefile. 2013-01-28 17:33:51 -08:00
Jef Poskanzer
a2adc385e2 Rename iperf.1 to iperf3.1. 2013-01-28 16:52:54 -08:00
Jef Poskanzer
2efc602fb2 The units handling was interpreting capital K/M/G as 1024/1048576/1073741824
and lowercase k/m/g as 1000/1000000/1000000000.  This was deemed to be
too confusing.  Now both capital and lowercase give the powers-of-two version.
2013-01-28 16:52:04 -08:00
Jef Poskanzer
1f4b249abb Better fix for the -u/-l argument parsing mixup. This one avoids
the problem of explicitly setting the UDP block size to the TCP default
and getting ignored.
2013-01-28 14:19:07 -08:00
Jef Poskanzer
1ac282ccdd Raise default UDP block size, for better performance. 2013-01-28 14:04:39 -08:00
Jef Poskanzer
45080fc6b7 Fixed little glitch in argument handling order: "-l nnn -u" was
setting the block size back to the UDP default, while "-u -l nnn"
worked.  Now both orders work.
2013-01-28 11:48:19 -08:00
Jef Poskanzer
6177a7f1f1 Get rid of extra select() calls before reading and writing,
in both client and server.  Instead we pass in and use the
fdsets from the main loop's select().
2013-01-18 10:17:05 -08:00
Jef Poskanzer
d7613a8e9f Allow API client to provide an fd for the client-side control socket. 2012-12-13 09:37:55 -08:00
Jef Poskanzer
5cd3317d98 Get rid of compiler warning. 2012-12-11 22:45:15 -08:00
Jef Poskanzer
88dd44b040 Need a couple more include files to compile on FreeBSD. 2012-12-11 22:41:37 -08:00
Jef Poskanzer
ec2d0670b8 Switched to using a new timer package, adapted from thttpd and http_load. 2012-12-11 22:29:26 -08:00
Jef Poskanzer
9673370f98 Move non-timer routines from timer.[hc] to iperf_util.[hc] 2012-12-05 12:34:58 -08:00
Jef Poskanzer
d6e2781d18 Better detection of when linux has retransmit info in tcp_info. 2012-12-03 22:02:31 -08:00
Jef Poskanzer
9d1fc7c676 Line up output columns better. 2012-12-03 16:20:49 -08:00
Jef Poskanzer
d7ebadafa4 Make the retransmits code compile again on systems without retransmits. 2012-12-03 16:00:14 -08:00
Jef Poskanzer
46baab59e8 Disable retransmit reporting for FreeBSD, it's not actually
implemented in the OS yet.
2012-12-03 15:50:29 -08:00
Jef Poskanzer
acad430d3d Fix retransmit reporting for Linux. 2012-12-03 15:48:54 -08:00
Jef Poskanzer
437537fe30 Test commit. 2012-11-30 12:16:17 -08:00
jef
eb3c71b8fe Don't do getsockopt(TCP_INFO) on UDP runs. 2012-11-30 10:13:25 -08:00
jef
874856ab6b Show retransmit count for FreeBSD too. This may not actually
be implemented by the OS yet - the struct member starting with
a double underscore indicates that it's not fully implemented.
2012-11-28 07:22:51 -08:00
jef
0d48915c69 A few portability changes, now builds on OSX without warnings. 2012-11-13 11:33:52 -08:00
jef
0115558217 Run uname for the -v/--version flag. Also, show version and uname for
the -V/--verbose flag.  Still debating whether version/uname should be
shown by default.
2012-11-12 10:01:26 -08:00
jef
6b7db8f774 Get rid of the -T/--tcpinfo flag and show retransmits if they
are available.

Also, show them in interval results as well as at the end.
2012-11-09 16:02:42 -08:00
jef
8a0cc10076 Testing timeval equality deserves to be its own routine. 2012-11-02 09:04:46 -07:00
jef
99502d9409 Re-jiggered the "Interval Transfer Bandwidth" header so it only
appears at the start and end of the results, and added a separator
line when there are both multiple streams and multiple intervals.
2012-10-29 22:30:31 -07:00
jef
7b43a90638 Switch the JSON parameter names from single letters to words.
That gets rid of the case-sensitivity issue, and is nicer.
2012-10-27 17:29:29 -07:00
jef
d23d944f12 Fix JSON parsing to handle very long ints better. Should still
do something better about them on output.
2012-10-27 16:43:04 -07:00
jef
ff3c7fba24 JSON names are case-insensitive so we have to use different
names for e.g. p and P.  I prefixed the upper case flags with "cap".
2012-10-27 16:24:54 -07:00
jef
53a87a0b9d Oops, -lm is still needed by cjson for floor(). Still worth getting
rid of pow() though.
2012-10-26 07:45:28 -07:00
jef
ea71aaeaee Fixed cjson to not need -lm any more, by adding an ipow() routine
to use instead of pow().
2012-10-25 22:14:02 -07:00
jef
4095757536 Converted the parameter exchange to use JSON.
This also gets rid of the antique tiny version of getopt that I added
to hack around a stubborn SEGV error.
2012-10-18 13:08:30 -07:00
jef
23481e7953 Converted the results exchange to use JSON. 2012-10-18 10:47:27 -07:00
jef
10d202a998 Simplify/clarify use of htonl/ntohl. 2012-10-17 09:14:14 -07:00
jef
0b96eba3e3 Move results-formatting into a new format_results() function.
Also, parse_results() doesn't need to be declared in iperf_api.h.
There are probably a whole bunch of other routines in there which
should be similarly made module-local.
2012-10-17 08:30:12 -07:00
jef
a497129b4d Oops, the cjson files need to be in the src directory.
Also changed the makefiles so that cjson gets compiled and linked in.
Next step: actually call it.
2012-10-15 09:49:20 -07:00
jef
8bb79aee26 Switched interval_results to use the queue.h macros. 2012-10-05 10:24:03 -07:00
jef
98ce496b1b Some changes to the iperf3 API to work with bwctl, mostly having to
do with what defs are in which include file.  End result is we now have
only one public include file, iperf_api.h.
2012-09-28 16:00:14 -07:00
jef
56a97f9337 Commented 'AX_LIB_SOCKET_NSL' out of configure.ac to fix build problem.
There's still lots of historical cruft in there, at some point we should
start over from a more modern template.
2012-08-20 14:35:58 -07:00
jef
2ab386bf13 Got rid of libuuid stuff, for portability. 2012-08-10 12:43:50 -07:00
Jon Dugan
94d391af37 Fix stats for multiple streams from Alexey Zaytsev <alexey.zaytsev@gmail.com> 2011-05-02 23:09:06 +00:00
Jon Dugan
7d375156aa update license info for all source files 2011-04-20 20:33:09 +00:00
sethdelliott
fecb120f91 Fixed TCP_INFO bug on linux. BSD prints nothing for now... 2011-03-16 18:17:54 +00:00
sethdelliott
e170832926 Added working TCP_INFO code (only displays retransmits for now) 2011-03-16 17:43:25 +00:00
sethdelliott
f970ce8ecd Added warning() function for iperf warnings. Using --server and --udp now gives a warning instead of an error. 2011-03-10 15:56:17 +00:00
sethdelliott
ad426c6fd4 Added CPU utilization exchange and display (use verbose mode [-V]). 2011-03-02 21:32:04 +00:00
sethdelliott
3331e801b9 Added portable CPU utilization code. Still need to exchange utilizations between client and server. 2011-02-24 17:08:54 +00:00
Jon Dugan
9286415c86 update autoconf goo to accomodate Solaris; minor tweaks to includes for Solaris 2010-09-20 21:50:12 +00:00
Jon Dugan
1fac1d2626 add queue.h from OpenBSD; use self contained queue.h from OpenBSD; fix indenting on previous commit 2010-09-08 20:35:47 +00:00
Jon Dugan
009a41300f if IPV6_TCLASS isn't defined do something reasonable 2010-09-08 20:33:54 +00:00
sethdelliott
2c206d5456 Critical server errors are now communicated back to client 2010-08-05 20:09:54 +00:00
sethdelliott
02a35f07e3 Merged print mss (-m) into verbose mode (-V) 2010-08-04 19:19:08 +00:00
sethdelliott
9a599d5f8d Added support for setting the IP TOS (IPv4) and IPv6 Traffic Class (-S option) 2010-08-03 21:38:48 +00:00
sethdelliott
76ceadbc24 Updated documentation 2010-08-02 23:30:22 +00:00
sethdelliott
0e8720fa64 Small memory leak fixes in iperf_free_test. 2010-08-02 23:15:27 +00:00
sethdelliott
0bd8d9da6e Added ability to set TCP window size (-w). Modified code to keep test structures intact after a test is complete. Improved interval timer granularity. Fixed a bug with timeval_diff. 2010-08-02 22:45:53 +00:00
sethdelliott
4559e27a01 Small bug fix to main.c 2010-07-29 19:18:29 +00:00
sethdelliott
dd4bc0089b Stream list is now managed by queue.h SLIST macros 2010-07-28 20:29:25 +00:00
sethdelliott
ffdcc7d457 Updated iperf_error and moved the SIGINT handler out of the library 2010-07-27 22:11:09 +00:00
sethdelliott
f99bd3b2c6 Added support for IPv6 mode (-6) 2010-07-27 20:27:34 +00:00
sethdelliott
5e0e1e974e Exchanged gethostbyname for getaddrinfo 2010-07-27 17:32:21 +00:00
sethdelliott
a1344ede16 Added support for binding (-B) to a specific interface 2010-07-26 21:30:34 +00:00
sethdelliott
eb85608f64 Updated autoconf files 2010-07-23 23:48:45 +00:00
sethdelliott
18631aacdb Moved client code from iperf_api.* to iperf_client_api.* 2010-07-23 22:48:48 +00:00
sethdelliott
2e3dfab7eb Updated documentation 2010-07-23 21:39:41 +00:00
sethdelliott
4df383f6d8 Added callback functions to the iperf API 2010-07-23 20:46:58 +00:00
sethdelliott
112a907cc3 More code restructuring 2010-07-23 18:39:14 +00:00
sethdelliott
66ce7ad49d Made the protocol implementation better. Lots of code clean up 2010-07-22 23:26:38 +00:00
sethdelliott
8a0b5a5d18 Added support for adding new protocols. Slightly modified iperf_error() 2010-07-22 18:57:08 +00:00
sethdelliott
b60a49dd37 All error handling is now handled by iperf_error. Also cleaned up some code 2010-07-20 22:27:50 +00:00
sethdelliott
3118b42010 All client side error handling is now handled by iperf_error 2010-07-20 00:03:03 +00:00
sethdelliott
01ca972b6c Updated autoconf stuff and fixed a small error with ierror() 2010-07-19 20:38:40 +00:00
sethdelliott
8430ad49e6 Added iperf error code (iperf_error.*). Also added iperf_parse_parameters(). 2010-07-19 19:45:08 +00:00
Jon Dugan
7585c69638 bump version number 2010-07-16 23:19:31 +00:00
sethdelliott
1e621fb16c Small updates to man page and documentation. 2010-07-15 23:38:10 +00:00
sethdelliott
c81883bf08 Added support for setting the MAXSEG (MSS) and NODELAY TCP options. Setting MSS is still a little buggy. 2010-07-15 23:19:42 +00:00
sethdelliott
aa89cda29f Added bandwidth mode (-b) support for UDP. 2010-07-15 20:05:43 +00:00