affected version: iperf3.16, iperf3.17, iperf3.18 till last commit
unaffected version: iperf3.15
kernel: Linux FTW1 5.10.221 #0 SMP Mon Jul 22 22:56:41 2024 x86_64 GNU/Linux
system: OpenWRT 22.03
iperf3 build info
root@FTW1:~# iperf3 -v
iperf 3.18+ (cJSON 1.7.15)
Linux FTW1 5.10.221 #0 SMP Mon Jul 22 22:56:41 2024 x86_64
Optional features available: CPU affinity setting, IPv6 flow label, TCP congestion algorithm setting, sendfile / zerocopy, socket pacing, bind to device, support IPv4 don't fragment, POSIX threads
If the snd-timeout parameter is set, I expect that when the interface is dropped after the timeout the iperf on the data sending side will be terminated. This does not happen.
If I restart the interface during the measurement, the server side is terminated, but the client side is not terminated.
Replication:
Server side:
root@FTServer-DK:~# iperf3 -s --rcv-timeout 3000 --snd-timeout 3000 -p 9999
-----------------------------------------------------------
Server listening on 9999 (test #1)
-----------------------------------------------------------
Accepted connection from 78.80.18.18, port 26762
[ 5] local 147.32.211.31 port 9999 connected to 78.80.18.18 port 26852
[ ID] Interval Transfer Bitrate
[ 5] 0.00-1.00 sec 128 KBytes 1.05 Mbits/sec
[ 5] 1.00-2.00 sec 128 KBytes 1.05 Mbits/sec
[ 5] 2.00-3.00 sec 128 KBytes 1.05 Mbits/sec
[ 5] 3.00-4.00 sec 128 KBytes 1.05 Mbits/sec
[ 5] 4.00-5.00 sec 128 KBytes 1.05 Mbits/sec
[ 5] 5.00-6.00 sec 0.00 Bytes 0.00 bits/sec <----------------- mobile network goes down
[ 5] 6.00-7.00 sec 0.00 Bytes 0.00 bits/sec
[ 5] 7.00-8.00 sec 0.00 Bytes 0.00 bits/sec
iperf3: error - idle timeout for receiving data
-----------------------------------------------------------
Server listening on 9999 (test #2)
-----------------------------------------------------------
Client side:
root@FTW1:~# iperf3 -c <IP> -p 9999 --snd-timeout 3000 --rcv-timeout 3000 -b 1M -t 600
Connecting to host 147.32.211.31, port 9999
[ 5] local 100.65.203.250 port 40958 connected to 147.32.211.31 port 9999
[ ID] Interval Transfer Bitrate Retr Cwnd
[ 5] 0.00-1.00 sec 128 KBytes 1.05 Mbits/sec 0 62.4 KBytes
[ 5] 1.00-2.00 sec 128 KBytes 1.05 Mbits/sec 0 62.4 KBytes
[ 5] 2.00-3.00 sec 128 KBytes 1.05 Mbits/sec 0 98.9 KBytes
[ 5] 3.00-4.00 sec 128 KBytes 1.05 Mbits/sec 0 104 KBytes
[ 5] 4.00-5.00 sec 128 KBytes 1.05 Mbits/sec 0 101 KBytes
[ 5] 5.00-6.00 sec 128 KBytes 1.05 Mbits/sec 0 101 KBytes
[ 5] 6.00-7.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes <----------------- mobile network goes down
[ 5] 7.00-8.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 8.00-9.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 9.00-10.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 10.00-11.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 11.00-12.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 12.00-13.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 13.00-14.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 14.00-15.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 15.00-16.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 16.00-17.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 17.00-18.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 18.00-19.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
[ 5] 19.00-20.00 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
^C[ 5] 20.00-20.12 sec 0.00 Bytes 0.00 bits/sec 0 1.30 KBytes
Right function in version 3.15
iperf3 3.15 build info
root@FTW1:~# iperf3 -v
iperf 3.15 (cJSON 1.7.15)
Linux FTW1 5.10.221 #0 SMP Mon Jul 22 22:56:41 2024 x86_64
Optional features available: CPU affinity setting, IPv6 flow label, TCP congestion algorithm setting, sendfile / zerocopy, socket pacing, bind to device, support IPv4 don't fragment
root@FTW1:~# iperf3 -c 147.32.211.31 -p 9999 --snd-timeout 3000 --rcv-timeout 3000 -b 1M -t 600
Connecting to host 147.32.211.31, port 9999
[ 5] local 100.115.99.196 port 47568 connected to 147.32.211.31 port 9999
[ ID] Interval Transfer Bitrate Retr Cwnd
[ 5] 0.00-1.00 sec 128 KBytes 1.05 Mbits/sec 0 74.2 KBytes
[ 5] 1.00-2.00 sec 128 KBytes 1.05 Mbits/sec 0 107 KBytes
[ 5] 2.00-3.00 sec 128 KBytes 1.05 Mbits/sec 0 129 KBytes
[ 5] 3.00-4.00 sec 128 KBytes 1.05 Mbits/sec 0 176 KBytes
[ 5] 4.00-5.00 sec 128 KBytes 1.05 Mbits/sec 0 176 KBytes
[ 5] 5.00-6.00 sec 128 KBytes 1.05 Mbits/sec 0 176 KBytes
[ 5] 6.00-7.00 sec 128 KBytes 1.05 Mbits/sec 0 176 KBytes
[ 5] 7.00-8.00 sec 128 KBytes 1.05 Mbits/sec 0 176 KBytes
[ 5] 8.00-9.00 sec 0.00 Bytes 0.00 bits/sec 0 4.50 KBytes <----------------- mobile network goes down
[ 5] 9.00-10.00 sec 0.00 Bytes 0.00 bits/sec 0 36.0 Bytes
[ 5] 9.00-10.00 sec 0.00 Bytes 0.00 bits/sec 0 36.0 Bytes
iperf3: error - unable to write to stream socket: Network unreachable
affected version: iperf3.16, iperf3.17, iperf3.18 till last commit
unaffected version: iperf3.15
kernel: Linux FTW1 5.10.221 #0 SMP Mon Jul 22 22:56:41 2024 x86_64 GNU/Linux
system: OpenWRT 22.03
iperf3 build info
If the snd-timeout parameter is set, I expect that when the interface is dropped after the timeout the iperf on the data sending side will be terminated. This does not happen.
If I restart the interface during the measurement, the server side is terminated, but the client side is not terminated.
Replication:
Server side:
Client side:
Right function in version 3.15
iperf3 3.15 build info