Skip to content

Instantly share code, notes, and snippets.

@gangliao
Created June 14, 2018 08:53
Show Gist options
  • Save gangliao/3b0c2b6a50ed1e46ae8e2b1e9389b0fe to your computer and use it in GitHub Desktop.
Save gangliao/3b0c2b6a50ed1e46ae8e2b1e9389b0fe to your computer and use it in GitHub Desktop.

Freeflow

TCP Physical Bandwidth

ethtool eth0 | grep Speed
# 	Speed: 1000Mb/s

demo test

bare metal

10.141.162.80:

yum install -y iperf3
iperf3 -s

10.141.170.36:

yum install -y iperf3
iperf3 -c 10.141.162.80 -V
Connecting to host 10.141.162.80, port 5201
[  4] local 10.141.170.36 port 51292 connected to 10.141.162.80 port 5201
[ ID] Interval           Transfer     Bandwidth       Retr  Cwnd
[  4]   0.00-1.00   sec   114 MBytes   958 Mbits/sec    0    397 KBytes
[  4]   1.00-2.00   sec   112 MBytes   942 Mbits/sec    0    397 KBytes
[  4]   2.00-3.00   sec   112 MBytes   942 Mbits/sec    0    397 KBytes
[  4]   3.00-4.00   sec   112 MBytes   942 Mbits/sec    0    417 KBytes
[  4]   4.00-5.00   sec   111 MBytes   935 Mbits/sec    0    417 KBytes
[  4]   5.00-6.00   sec   113 MBytes   944 Mbits/sec    0    417 KBytes
[  4]   6.00-7.00   sec   113 MBytes   945 Mbits/sec    0    417 KBytes
[  4]   7.00-8.00   sec   112 MBytes   942 Mbits/sec    0    417 KBytes
[  4]   8.00-9.00   sec   111 MBytes   935 Mbits/sec    0    443 KBytes
[  4]   9.00-10.00  sec   112 MBytes   941 Mbits/sec    0    443 KBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth       Retr
[  4]   0.00-10.00  sec  1.10 GBytes   943 Mbits/sec    0             sender
[  4]   0.00-10.00  sec  1.10 GBytes   941 Mbits/sec                  receiver
CPU Utilization: local/sender 2.2% (0.1%u/2.1%s), remote/receiver 3.1% (0.2%u/2.8%s)

Baseline with Flannel

10.141.162.80:

sudo docker run -it --entrypoint /bin/bash --name iperf networkstatic/iperf3
ip addr show  # 172.30.81.4
iperf3 -s

10.141.170.36:

sudo docker run -it --entrypoint /bin/bash --name iperf networkstatic/iperf3
iperf3 -c 172.30.81.4 -V
Starting Test: protocol: TCP, 1 streams, 131072 byte blocks, omitting 0 seconds, 10 second test
[ ID] Interval           Transfer     Bandwidth       Retr  Cwnd
[  4]   0.00-1.00   sec   112 MBytes   936 Mbits/sec    0   1.58 MBytes
[  4]   1.00-2.00   sec   109 MBytes   912 Mbits/sec    0   1.58 MBytes
[  4]   2.00-3.00   sec   108 MBytes   902 Mbits/sec    0   1.58 MBytes
[  4]   3.00-4.00   sec   109 MBytes   912 Mbits/sec    0   1.58 MBytes
[  4]   4.00-5.00   sec   108 MBytes   902 Mbits/sec    0   1.58 MBytes
[  4]   5.00-6.00   sec   109 MBytes   912 Mbits/sec    0   1.58 MBytes
[  4]   6.00-7.00   sec   109 MBytes   912 Mbits/sec    0   1.58 MBytes
[  4]   7.00-8.00   sec   108 MBytes   902 Mbits/sec    0   1.58 MBytes
[  4]   8.00-9.00   sec   109 MBytes   912 Mbits/sec    0   1.58 MBytes
[  4]   9.00-10.00  sec   108 MBytes   902 Mbits/sec    0   1.58 MBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
Test Complete. Summary Results:
[ ID] Interval           Transfer     Bandwidth       Retr
[  4]   0.00-10.00  sec  1.06 GBytes   910 Mbits/sec    0             sender
[  4]   0.00-10.00  sec  1.06 GBytes   909 Mbits/sec                  receiver
CPU Utilization: local/sender 2.9% (0.1%u/2.8%s), remote/receiver 0.8% (0.1%u/0.7%s)

FreeFlow

10.141.186.119:

sudo docker run -d -it --privileged --net=host -v /freeflow:/freeflow -e "HOST_IP_PREFIX=10.141.184.0/21" --name freeflow freeflow/freeflow:tcp

sudo docker run -it --entrypoint /bin/bash -v /freeflow:/freeflow -e "VNET_PREFIX=172.30.0.0/16" -e "LD_PRELOAD=/freeflow/libfsocket.so" --name iperf networkstatic/iperf3

ip addr show  # 172.30.92.18
iperf3 -s

10.141.186.118:

sudo docker run -d -it --privileged --net=host -v /freeflow:/freeflow -e "HOST_IP_PREFIX=10.141.184.0/21" --name freeflow freeflow/freeflow:tcp

sudo docker run -it --entrypoint /bin/bash -v /freeflow:/freeflow -e "VNET_PREFIX=172.30.0.0/16" -e "LD_PRELOAD=/freeflow/libfsocket.so" --name iperf networkstatic/iperf3

iperf3 -c 172.30.92.18 -V
Starting Test: protocol: TCP, 1 streams, 131072 byte blocks, omitting 0 seconds, 10 second test
[ ID] Interval           Transfer     Bandwidth       Retr  Cwnd
[  5]   0.00-1.00   sec   114 MBytes   954 Mbits/sec    0   13.7 KBytes
[  5]   1.00-2.00   sec   112 MBytes   943 Mbits/sec    0   13.7 KBytes
[  5]   2.00-3.00   sec   113 MBytes   946 Mbits/sec    0   13.7 KBytes
[  5]   3.00-4.00   sec   112 MBytes   936 Mbits/sec    0   13.7 KBytes
[  5]   4.00-5.00   sec   113 MBytes   948 Mbits/sec    0   13.7 KBytes
[  5]   5.00-6.00   sec   112 MBytes   943 Mbits/sec    0   13.7 KBytes
[  5]   6.00-7.00   sec   112 MBytes   938 Mbits/sec    0   13.7 KBytes
[  5]   7.00-8.00   sec   111 MBytes   935 Mbits/sec    0   13.7 KBytes
[  5]   8.00-9.00   sec   113 MBytes   948 Mbits/sec    0   13.7 KBytes
[  5]   9.00-10.00  sec   112 MBytes   939 Mbits/sec    0   13.7 KBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
Test Complete. Summary Results:
[ ID] Interval           Transfer     Bandwidth       Retr
[  5]   0.00-10.00  sec  1.10 GBytes   943 Mbits/sec    0             sender
[  5]   0.00-10.00  sec  1.10 GBytes   941 Mbits/sec                  receiver
CPU Utilization: local/sender 1.6% (0.2%u/1.5%s), remote/receiver 3.6% (0.4%u/3.2%s)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment