iperf icon indicating copy to clipboard operation
iperf copied to clipboard

client (--client) should send results to server (--server)

Open TheRealDJ opened this issue 2 years ago • 0 comments

Context

  • Version of iperf3: 3.12
  • Hardware: KVM
  • Operating system (and distribution, if any): CentOS
  • Other relevant information (for example, non-default compilers, libraries, cross-compiling, etc.): ./configure --disable-static --disable-shared && make

Bug Report

  • Expected Behavior: Server JSON output should have the full result.
  • Actual Behavior: Server JSON has zeros for bytes, bits_per_second (and jitter_ms, lost_packets, packets and lost_percent for a downstream UDP test). The server would need to get these results from the client as the server wouldn't know these values. This occurs for server's sum_sent for an upstream test and sum_received for a downstream test (--reverse).
  • Steps to Reproduce
    • Server: iperf3 --server --json
    • Client: iperf3 --client XXX --reverse [--udp]
  • Possible Solution: I believe this should be fairly easy as the client is already sending the relevant details to the server. This can be seen with the client and/or server in debug mode (--debug). I can't seem to find the code that includes the server's result data in the client.

Example Server Output for upstream test from client:

get_results
{
	"cpu_util_total":	6.6487283974503457,
	"cpu_util_user":	0.73126039279357624,
	"cpu_util_system":	6.248840627985695,
	"sender_has_retransmits":	0,
	"streams":	[{
			"id":	1,
			"bytes":	3751936,
			"retransmits":	1.8446744073709552e+19,
			"jitter":	0,
			"errors":	0,
			"packets":	229,
			"start_time":	0,
			"end_time":	3.000103
		}, {
			"id":	3,
			"bytes":	3751936,
			"retransmits":	1.8446744073709552e+19,
			"jitter":	0,
			"errors":	0,
			"packets":	229,
			"start_time":	0,
			"end_time":	3.000104
		}]
}
...
"sum_sent":	{
	"start":	0,
	"end":	3.00269,
	"seconds":	3.00269,
	"bytes":	0,
	"bits_per_second":	0,
	"jitter_ms":	0,
	"lost_packets":	0,
	"packets":	0,
	"lost_percent":	0,
	"sender":	true
},
"sum_received":	{
	"start":	0,
	"end":	3.00269,
	"seconds":	3.00269,
	"bytes":	7503872,
	"bits_per_second":	19992398.815728564,
	"jitter_ms":	0.0138530240674317,
	"lost_packets":	0,
	"packets":	458,
	"lost_percent":	0,
	"sender":	false
}

Example Server Output for downstream (--reverse) test from client:

get_results
{
	"cpu_util_total":	0,
	"cpu_util_user":	0.099650194600221675,
	"cpu_util_system":	0.3321008818710055,
	"sender_has_retransmits":	1.8446744073709552e+19,
	"streams":	[{
			"id":	1,
			"bytes":	3751936,
			"retransmits":	1.8446744073709552e+19,
			"jitter":	1.859010951280376e-05,
			"errors":	0,
			"packets":	229,
			"start_time":	0,
			"end_time":	3.000152
		}, {
			"id":	3,
			"bytes":	3751936,
			"retransmits":	1.8446744073709552e+19,
			"jitter":	5.4381090362488954e-06,
			"errors":	0,
			"packets":	229,
			"start_time":	0,
			"end_time":	3.000153
		}]
}
...
"sum_sent":	{
	"start":	0,
	"end":	3.000182,
	"seconds":	3.000182,
	"bytes":	7503872,
	"bits_per_second":	20009111.447238866,
	"jitter_ms":	0,
	"lost_packets":	0,
	"packets":	458,
	"lost_percent":	0,
	"sender":	true
},
"sum_received":	{
	"start":	0,
	"end":	3.000182,
	"seconds":	3.000182,
	"bytes":	0,
	"bits_per_second":	0,
	"jitter_ms":	0,
	"lost_packets":	0,
	"packets":	0,
	"lost_percent":	0,
	"sender":	false
}

TheRealDJ avatar Oct 24 '22 22:10 TheRealDJ