-
Notifications
You must be signed in to change notification settings - Fork 47
Open
Description
Bandwitch limit is not working as expected, the expirimented limit is much higher than the value I setted via the label. Here some examples:
- Without limitation, as you can see, we get 10Gbps.
$ docker run -it mlabbe/iperf3 iperf3 -c 172.20.35.249
Connecting to host 172.20.35.249, port 5201
[ 5] local 172.17.0.2 port 49944 connected to 172.20.35.249 port 5201
[ ID] Interval Transfer Bitrate Retr Cwnd
[ 5] 0.00-1.00 sec 1.28 GBytes 11.0 Gbits/sec 12 3.06 MBytes
[ 5] 1.00-2.00 sec 1.20 GBytes 10.3 Gbits/sec 0 3.06 MBytes
[ 5] 2.00-3.00 sec 1.29 GBytes 11.1 Gbits/sec 0 3.06 MBytes
[ 5] 3.00-4.00 sec 1.33 GBytes 11.4 Gbits/sec 0 3.06 MBytes
[ 5] 4.00-5.00 sec 1.33 GBytes 11.4 Gbits/sec 0 3.06 MBytes
[ 5] 5.00-6.00 sec 1.27 GBytes 10.9 Gbits/sec 0 3.06 MBytes
[ 5] 6.00-7.00 sec 1.19 GBytes 10.2 Gbits/sec 0 3.06 MBytes
[ 5] 7.00-8.00 sec 1.13 GBytes 9.68 Gbits/sec 0 3.06 MBytes
[ 5] 8.00-9.00 sec 1.02 GBytes 8.75 Gbits/sec 0 3.06 MBytes
[ 5] 9.00-10.00 sec 882 MBytes 7.40 Gbits/sec 0 3.06 MBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Retr
[ 5] 0.00-10.00 sec 11.9 GBytes 10.2 Gbits/sec 12 sender
[ 5] 0.00-10.04 sec 11.9 GBytes 10.2 Gbits/sec receiver
- With the limit setted at 1mbps (which actually means 1 MB/s), we get around 230 Mbps
$ docker network create test5-net
7c5df3e208dd7a1faccc909848292c7bd93d24e6c871858fa10ede948f30c54f
$ docker run -it \
--net test5-net \
--label "com.docker-tc.enabled=1" \
--label "com.docker-tc.limit=1mbps" \
--label "com.docker-tc.delay=100ms" \
--label "com.docker-tc.loss=10%" \
--label "com.docker-tc.duplicate=5%" \
--label "com.docker-tc.corrupt=1%" \
mlabbe/iperf3 \
iperf3 -c 172.20.35.249
Connecting to host 172.20.35.249, port 5201
[ 5] local 172.23.0.2 port 37802 connected to 172.20.35.249 port 5201
[ ID] Interval Transfer Bitrate Retr Cwnd
[ 5] 0.00-1.00 sec 1.13 GBytes 9.67 Gbits/sec 12 3.10 MBytes
[ 5] 1.00-2.00 sec 1.10 GBytes 9.50 Gbits/sec 0 3.10 MBytes
[ 5] 2.00-3.00 sec 31.2 MBytes 263 Mbits/sec 1 2.32 MBytes
[ 5] 3.00-4.00 sec 23.8 MBytes 199 Mbits/sec 0 2.51 MBytes
[ 5] 4.00-5.00 sec 26.2 MBytes 220 Mbits/sec 0 2.67 MBytes
[ 5] 5.00-6.00 sec 27.5 MBytes 231 Mbits/sec 0 2.79 MBytes
[ 5] 6.00-7.00 sec 27.5 MBytes 231 Mbits/sec 0 2.89 MBytes
[ 5] 7.00-8.00 sec 27.5 MBytes 231 Mbits/sec 0 2.96 MBytes
[ 5] 8.00-9.00 sec 28.8 MBytes 241 Mbits/sec 0 3.02 MBytes
[ 5] 9.00-10.00 sec 30.0 MBytes 252 Mbits/sec 0 3.02 MBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Retr
[ 5] 0.00-10.00 sec 2.45 GBytes 2.11 Gbits/sec 13 sender
[ 5] 0.00-10.04 sec 2.45 GBytes 2.10 Gbits/sec receiver
- With the limit setted at 256kbps (which actually means 256 MB/s), we get around 230Mbps
$ docker network create test7-net
f91ccaaf402391584ba6afb17dfd1260d91df04f24b76df272c62520a1c520f1
$ docker run -it \
--net test7-net \
--label "com.docker-tc.enabled=1" \
--label "com.docker-tc.limit=256kbps" \
--label "com.docker-tc.delay=100ms" \
--label "com.docker-tc.loss=10%" \
--label "com.docker-tc.duplicate=5%" \
--label "com.docker-tc.corrupt=1%" \
mlabbe/iperf3 \
iperf3 -c 172.20.35.249
Connecting to host 172.20.35.249, port 5201
[ 5] local 172.25.0.2 port 49744 connected to 172.20.35.249 port 5201
[ ID] Interval Transfer Bitrate Retr Cwnd
[ 5] 0.00-1.00 sec 1.10 GBytes 9.44 Gbits/sec 12 3.02 MBytes
[ 5] 1.00-2.00 sec 806 MBytes 6.76 Gbits/sec 1 3.02 MBytes
[ 5] 2.00-3.00 sec 28.8 MBytes 241 Mbits/sec 0 3.02 MBytes
[ 5] 3.00-4.00 sec 28.8 MBytes 241 Mbits/sec 0 3.02 MBytes
[ 5] 4.00-5.00 sec 30.0 MBytes 252 Mbits/sec 0 3.02 MBytes
[ 5] 5.00-6.00 sec 27.5 MBytes 231 Mbits/sec 0 3.02 MBytes
[ 5] 6.00-7.00 sec 27.5 MBytes 231 Mbits/sec 0 3.02 MBytes
[ 5] 7.00-8.00 sec 28.8 MBytes 241 Mbits/sec 0 3.02 MBytes
[ 5] 8.00-9.00 sec 30.0 MBytes 252 Mbits/sec 0 3.02 MBytes
[ 5] 9.00-10.00 sec 28.8 MBytes 241 Mbits/sec 0 3.02 MBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Retr
[ 5] 0.00-10.00 sec 2.11 GBytes 1.81 Gbits/sec 13 sender
[ 5] 0.00-10.04 sec 2.11 GBytes 1.80 Gbits/sec receiver
Do you know where is the problem? I created a new network for each container, I don't know if that's right. I'm using the docker compose YAML to run docker-tc. I'm using Ubuntu Server 18.04 and Docker 19.03.8.
Thanks,
Xoán
Metadata
Metadata
Assignees
Labels
No labels