* [Make-wifi-fast] iperf enhancements in 2.0.8
@ 2015-10-16 4:19 Bob (Robert) McMahon
2015-10-16 8:52 ` Toke Høiland-Jørgensen
0 siblings, 1 reply; 7+ messages in thread
From: Bob (Robert) McMahon @ 2015-10-16 4:19 UTC (permalink / raw)
To: make-wifi-fast
[-- Attachment #1: Type: text/plain, Size: 2665 bytes --]
Hi,
Just an FYI for those who might be interested. We added RTT and CWND samples in iperf 2.0.8<https://sourceforge.net/projects/iperf2/> for the TCP transmitter (iperf client) as well as UDP mean/min/max/stdev in the iperf server (assumes the clocks are synched.) Also, much faster sampling is supported. These may be helpful to those trying to improve wi-fi performance. To get the output one needs to use the -e option. Also, RTT/CWND is linux only. Apple is evaluating the change set and *may* ship it with future phones and Mac OS X systems.
Full change set here:
* Fix portability, compile and tested with Linux, Win10, Win7, WinXP, MacOS and Android
* Require -u for UDP (-b no longer defaults to UDP)
* Improved performance
* Enhanced reporting with -e
* Support smaller report intervals (5 ms or greater)
* Support SO_RCVTIMEOUT for server reports regardless of no packets
* Server will close the socket after no received traffic per the -t value (default is 10 sec)
* Support SO_TIMESTAMP for kernel level packet timestamping
* Support end/end latency in mean/min/max/stdev format (UDP) (-e required)
* (assumes client and server clocks synched, e.g by Precision Time Protocol)
* Add local port to bind support (-B option) using colon as separator
* (e.g. iperf -c 192.168.100.100 -B 192.168.100.10:6001)
* Support TCP rate limited streams (via the -b) using token bucket
* Support packets per second (UDP) via pps as units, (e.g. -b 1000pps)
* Display PPS in both client and server reports (UDP) (-e required)
* Support realtime scheduler as a command line option (--realtime or -z, assumes proper user privileges)
* Improve client tx code path so actual tx offered rate will converge to the -b value
* Improve accuracy of microsecond delay calls (in platform independent manner)
* (Use of Kalman filter to predict delay errors and adjust delays per predicted error)
* Display target loop time in initial client header (UDP)
* Fix final latency report sent from server to client (UDP)
* Include standard deviation in latency output
* Suppress unrealistic latency output using (-/-/-/-)
* Support SO_SNDTIMEO on send so socket write won't block beyond -t (TCP)
* Use clock_gettime if available (preferred over gettimeofday())
* TCP write and error counts (TCP retries and CWND for linux) (-e required)
* TCP read count, TCP read histogram (8 bins) (-e required)
* TCP RTT and CWND values in client reports (-e required, Linux only, RTT units microseconds)
Bob McMahon
Broadcom Wi-Fi QA Engineer
[-- Attachment #2: Type: text/html, Size: 12778 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Make-wifi-fast] iperf enhancements in 2.0.8
2015-10-16 4:19 [Make-wifi-fast] iperf enhancements in 2.0.8 Bob (Robert) McMahon
@ 2015-10-16 8:52 ` Toke Høiland-Jørgensen
2015-10-16 16:03 ` Bob (Robert) McMahon
0 siblings, 1 reply; 7+ messages in thread
From: Toke Høiland-Jørgensen @ 2015-10-16 8:52 UTC (permalink / raw)
To: Bob (Robert) McMahon; +Cc: make-wifi-fast
"Bob (Robert) McMahon" <rmcmahon@broadcom.com> writes:
> Just an FYI for those who might be interested. We added RTT and CWND
> samples in iperf 2.0.8 for the TCP transmitter (iperf client) as well
> as UDP mean/min/max/stdev in the iperf server (assumes the clocks are
> synched.) Also, much faster sampling is supported. These may be
> helpful to those trying to improve wi-fi performance. To get the
> output one needs to use the –e option. Also, RTT/CWND is linux only.
> Apple is evaluating the change set and *may* ship it with future
> phones and Mac OS X systems.
Hi Bob
Any chance of getting the below patch into Iperf? Or in general, getting
sub-second resolution on the timestamps output in CSV mode? Would make
it easier to integrate Iperf into Flent tests (where the timestamps are
used to match the output with other simultaneous test tools).
-Toke
--- a/src/ReportCSV.c 2007-08-29 23:57:27.000000000 +0200
+++ b/src/ReportCSV.c 2012-10-17 15:54:46.516986280 +0200
@@ -149,9 +149,8 @@
}
void CSV_timestamp( char *timestamp, int length ) {
- time_t times;
- struct tm *timest;
- times = time( NULL );
- timest = localtime( × );
- strftime( timestamp, length,"%Y%m%d%H%M%S", timest );
+ struct timeval tv;
+ gettimeofday(&tv, NULL);
+ snprintf(timestamp, length, "%lu.%06lu",
+ (unsigned long)tv.tv_sec, (unsigned long)tv.tv_usec);
}
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Make-wifi-fast] iperf enhancements in 2.0.8
2015-10-16 8:52 ` Toke Høiland-Jørgensen
@ 2015-10-16 16:03 ` Bob (Robert) McMahon
2015-10-21 0:06 ` Bob (Robert) McMahon
0 siblings, 1 reply; 7+ messages in thread
From: Bob (Robert) McMahon @ 2015-10-16 16:03 UTC (permalink / raw)
To: toke; +Cc: make-wifi-fast
Sure, will do. I'll apply the below diff, test it, and then commit. Thanks for the diff.
Bob
-----Original Message-----
From: toke@toke.dk [mailto:toke@toke.dk]
Sent: Friday, October 16, 2015 1:53 AM
To: Bob (Robert) McMahon
Cc: make-wifi-fast@lists.bufferbloat.net
Subject: Re: [Make-wifi-fast] iperf enhancements in 2.0.8
"Bob (Robert) McMahon" <rmcmahon@broadcom.com> writes:
> Just an FYI for those who might be interested. We added RTT and CWND
> samples in iperf 2.0.8 for the TCP transmitter (iperf client) as well
> as UDP mean/min/max/stdev in the iperf server (assumes the clocks are
> synched.) Also, much faster sampling is supported. These may be
> helpful to those trying to improve wi-fi performance. To get the
> output one needs to use the –e option. Also, RTT/CWND is linux only.
> Apple is evaluating the change set and *may* ship it with future
> phones and Mac OS X systems.
Hi Bob
Any chance of getting the below patch into Iperf? Or in general, getting
sub-second resolution on the timestamps output in CSV mode? Would make
it easier to integrate Iperf into Flent tests (where the timestamps are
used to match the output with other simultaneous test tools).
-Toke
--- a/src/ReportCSV.c 2007-08-29 23:57:27.000000000 +0200
+++ b/src/ReportCSV.c 2012-10-17 15:54:46.516986280 +0200
@@ -149,9 +149,8 @@
}
void CSV_timestamp( char *timestamp, int length ) {
- time_t times;
- struct tm *timest;
- times = time( NULL );
- timest = localtime( × );
- strftime( timestamp, length,"%Y%m%d%H%M%S", timest );
+ struct timeval tv;
+ gettimeofday(&tv, NULL);
+ snprintf(timestamp, length, "%lu.%06lu",
+ (unsigned long)tv.tv_sec, (unsigned long)tv.tv_usec);
}
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Make-wifi-fast] iperf enhancements in 2.0.8
2015-10-16 16:03 ` Bob (Robert) McMahon
@ 2015-10-21 0:06 ` Bob (Robert) McMahon
2015-10-21 11:37 ` Toke Høiland-Jørgensen
0 siblings, 1 reply; 7+ messages in thread
From: Bob (Robert) McMahon @ 2015-10-21 0:06 UTC (permalink / raw)
To: 'toke@toke.dk'; +Cc: 'make-wifi-fast@lists.bufferbloat.net'
Hi Toke,
I made a few changes to your proposal in order to preserve backwards compatibility as well as used clock_gettime() vs gettimeofday() when available.
Diff set is:
http://sourceforge.net/p/iperf2/code/ci/aa548905fc61300da0bd1705a4ed8366e9ddf084/
One can get the millisecond timestamps in the CSV two ways
1) use the -e option (for enhanced reporting)
2) use a value of less than 0.5 seconds for -i which enables enhanced reports without requiring -e (previous iperf verisons don't support faster than 0.5 sec so it's assumed a user setting it faster will also want enhanced reports)
For a 2.0.9 release, I plan to add all the new stats to CSV reporting as well as improve the udp packet accounting. Sub grouping (shewart's and cusum control charts) and inline mean shift detection support is also under consideration.
https://en.wikipedia.org/wiki/Mean_shift
Please do let me know if there are other things that could be useful. Making wi-fi fast and getting rid of bloat is a good thing for the networking industry to accomplish :)
Thanks,
Bob
-----Original Message-----
From: Bob (Robert) McMahon
Sent: Friday, October 16, 2015 9:03 AM
To: toke@toke.dk
Cc: make-wifi-fast@lists.bufferbloat.net
Subject: RE: [Make-wifi-fast] iperf enhancements in 2.0.8
Sure, will do. I'll apply the below diff, test it, and then commit. Thanks for the diff.
Bob
-----Original Message-----
From: toke@toke.dk [mailto:toke@toke.dk]
Sent: Friday, October 16, 2015 1:53 AM
To: Bob (Robert) McMahon
Cc: make-wifi-fast@lists.bufferbloat.net
Subject: Re: [Make-wifi-fast] iperf enhancements in 2.0.8
"Bob (Robert) McMahon" <rmcmahon@broadcom.com> writes:
> Just an FYI for those who might be interested. We added RTT and CWND
> samples in iperf 2.0.8 for the TCP transmitter (iperf client) as well
> as UDP mean/min/max/stdev in the iperf server (assumes the clocks are
> synched.) Also, much faster sampling is supported. These may be
> helpful to those trying to improve wi-fi performance. To get the
> output one needs to use the –e option. Also, RTT/CWND is linux only.
> Apple is evaluating the change set and *may* ship it with future
> phones and Mac OS X systems.
Hi Bob
Any chance of getting the below patch into Iperf? Or in general, getting sub-second resolution on the timestamps output in CSV mode? Would make it easier to integrate Iperf into Flent tests (where the timestamps are used to match the output with other simultaneous test tools).
-Toke
--- a/src/ReportCSV.c 2007-08-29 23:57:27.000000000 +0200
+++ b/src/ReportCSV.c 2012-10-17 15:54:46.516986280 +0200
@@ -149,9 +149,8 @@
}
void CSV_timestamp( char *timestamp, int length ) {
- time_t times;
- struct tm *timest;
- times = time( NULL );
- timest = localtime( × );
- strftime( timestamp, length,"%Y%m%d%H%M%S", timest );
+ struct timeval tv;
+ gettimeofday(&tv, NULL);
+ snprintf(timestamp, length, "%lu.%06lu",
+ (unsigned long)tv.tv_sec, (unsigned long)tv.tv_usec);
}
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Make-wifi-fast] iperf enhancements in 2.0.8
2015-10-21 0:06 ` Bob (Robert) McMahon
@ 2015-10-21 11:37 ` Toke Høiland-Jørgensen
2015-10-21 22:19 ` Bob (Robert) McMahon
0 siblings, 1 reply; 7+ messages in thread
From: Toke Høiland-Jørgensen @ 2015-10-21 11:37 UTC (permalink / raw)
To: Bob (Robert) McMahon; +Cc: 'make-wifi-fast@lists.bufferbloat.net'
"Bob (Robert) McMahon" <rmcmahon@broadcom.com> writes:
> One can get the millisecond timestamps in the CSV two ways
>
> 1) use the -e option (for enhanced reporting)
> 2) use a value of less than 0.5 seconds for -i which enables
> enhanced reports without requiring -e (previous iperf verisons
> don't support faster than 0.5 sec so it's assumed a user setting
> it faster will also want enhanced reports)
Awesome, thanks! I'll add support for this to Flent. Is there a way to
detect whether or not iperf supports this extended timestamp format,
other than looking at the actual output? E.g. a command line switch that
will fail if the support is not there, something or grep for in a help
output or the like?
-Toke
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Make-wifi-fast] iperf enhancements in 2.0.8
2015-10-21 11:37 ` Toke Høiland-Jørgensen
@ 2015-10-21 22:19 ` Bob (Robert) McMahon
2015-10-26 16:15 ` Toke Høiland-Jørgensen
0 siblings, 1 reply; 7+ messages in thread
From: Bob (Robert) McMahon @ 2015-10-21 22:19 UTC (permalink / raw)
To: toke; +Cc: 'make-wifi-fast@lists.bufferbloat.net'
Hi Toke,
I just committed -e, --enhancedreports information to the -h help text. One can grep that output to see if the functionality is supported or not. You'll need to pick up the latest from sourceforge.
[rmcmahon@rjm-sfast-utf:~/UTF/svn/unittest] $ /projects/hnd_sig_ext16/rmcmahon/Code/iperf/sourceforge/iperf2-code/src/iperf -h
Usage: iperf [-s|-c host] [options]
iperf [-h|--help] [-v|--version]
Client/Server:
-b, --bandwidth #[KMG | pps] bandwidth to send at in bits/sec or packets per second
-e, --enhancedreports use enhanced reporting giving more tcp/udp and traffic information
-f, --format [kmKM] format to report: Kbits, Mbits, KBytes, MBytes
...
Bob
-----Original Message-----
From: toke@toke.dk [mailto:toke@toke.dk]
Sent: Wednesday, October 21, 2015 4:38 AM
To: Bob (Robert) McMahon
Cc: 'make-wifi-fast@lists.bufferbloat.net'
Subject: Re: [Make-wifi-fast] iperf enhancements in 2.0.8
"Bob (Robert) McMahon" <rmcmahon@broadcom.com> writes:
> One can get the millisecond timestamps in the CSV two ways
>
> 1) use the -e option (for enhanced reporting)
> 2) use a value of less than 0.5 seconds for -i which enables
> enhanced reports without requiring -e (previous iperf verisons
> don't support faster than 0.5 sec so it's assumed a user setting
> it faster will also want enhanced reports)
Awesome, thanks! I'll add support for this to Flent. Is there a way to detect whether or not iperf supports this extended timestamp format, other than looking at the actual output? E.g. a command line switch that will fail if the support is not there, something or grep for in a help output or the like?
-Toke
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Make-wifi-fast] iperf enhancements in 2.0.8
2015-10-21 22:19 ` Bob (Robert) McMahon
@ 2015-10-26 16:15 ` Toke Høiland-Jørgensen
0 siblings, 0 replies; 7+ messages in thread
From: Toke Høiland-Jørgensen @ 2015-10-26 16:15 UTC (permalink / raw)
To: Bob (Robert) McMahon; +Cc: 'make-wifi-fast@lists.bufferbloat.net'
"Bob (Robert) McMahon" <rmcmahon@broadcom.com> writes:
> I just committed -e, --enhancedreports information to the -h help
> text. One can grep that output to see if the functionality is
> supported or not. You'll need to pick up the latest from sourceforge.
Right, awesome! Flent can now detect and use this, and the Iperf support
has been brought up to date.
Still no tests that use Iperf, but adding them is quite straight forward
now :)
BTW, the Iperf --help output has this:
-V, --IPv6Version Set the domain to IPv6
while the actual long option is --ipv6_domain.
-Toke
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2015-10-26 16:15 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-16 4:19 [Make-wifi-fast] iperf enhancements in 2.0.8 Bob (Robert) McMahon
2015-10-16 8:52 ` Toke Høiland-Jørgensen
2015-10-16 16:03 ` Bob (Robert) McMahon
2015-10-21 0:06 ` Bob (Robert) McMahon
2015-10-21 11:37 ` Toke Høiland-Jørgensen
2015-10-21 22:19 ` Bob (Robert) McMahon
2015-10-26 16:15 ` Toke Høiland-Jørgensen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox