网卡直通性能和桥接性能对比
一 实验环境
硬件环境:
主板:NF5270M3
网卡:I350 *2 firmware-version: 1.61
CPU: E5-2670 v2
软件环境:
Proxmox VE 7.2 with kernel 5.15.30-2-pve
VM:
Ubuntu 18.04.6 LTS with kernel 4.15.0-180-generic igb version: 5.4.0-k
二 实验方案
将网卡分别直通到2个虚拟机,由一根六类线串联。并且使用iperf3进行打流测试。
三 开始实验
直通测试
测试tcp
iperf3 -c 10.2.2.2 -t 20
结果如下
root@nettest1:~# iperf3 -c 10.2.2.2 -t 20
Connecting to host 10.2.2.2, port 5201
[ 4] local 10.2.2.1 port 49162 connected to 10.2.2.2 port 5201
[ ID] Interval Transfer Bandwidth Retr Cwnd
[ 4] 0.00-1.00 sec 114 MBytes 960 Mbits/sec 0 385 KBytes
[ 4] 1.00-2.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 2.00-3.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 3.00-4.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 4.00-5.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 5.00-6.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 6.00-7.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 7.00-8.00 sec 112 MBytes 942 Mbits/sec 0 385 KBytes
[ 4] 8.00-9.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 9.00-10.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 10.00-11.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 11.00-12.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 12.00-13.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 13.00-14.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 14.00-15.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 15.00-16.00 sec 112 MBytes 942 Mbits/sec 0 385 KBytes
[ 4] 16.00-17.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 17.00-18.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 18.00-19.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
[ 4] 19.00-20.00 sec 112 MBytes 941 Mbits/sec 0 385 KBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bandwidth Retr
[ 4] 0.00-20.00 sec 2.19 GBytes 942 Mbits/sec 0 sender
[ 4] 0.00-20.00 sec 2.19 GBytes 942 Mbits/sec receiver
udp
iperf3 -c 10.2.2.2 -t 20 -u -b 1024m
root@nettest1:~# iperf3 -c 10.2.2.2 -t 20 -u -b 1024m
Connecting to host 10.2.2.2, port 5201
[ 4] local 10.2.2.1 port 49634 connected to 10.2.2.2 port 5201
[ ID] Interval Transfer Bandwidth Total Datagrams
[ 4] 0.00-1.00 sec 103 MBytes 863 Mbits/sec 13163
[ 4] 1.00-2.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 2.00-3.00 sec 114 MBytes 958 Mbits/sec 14613
[ 4] 3.00-4.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 4.00-5.00 sec 114 MBytes 958 Mbits/sec 14622
[ 4] 5.00-6.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 6.00-7.00 sec 114 MBytes 958 Mbits/sec 14621
[ 4] 7.00-8.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 8.00-9.00 sec 114 MBytes 958 Mbits/sec 14623
[ 4] 9.00-10.00 sec 114 MBytes 958 Mbits/sec 14624
[ 4] 10.00-11.00 sec 114 MBytes 958 Mbits/sec 14624
[ 4] 11.00-12.00 sec 114 MBytes 958 Mbits/sec 14622
[ 4] 12.00-13.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 13.00-14.00 sec 114 MBytes 958 Mbits/sec 14622
[ 4] 14.00-15.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 15.00-16.00 sec 114 MBytes 958 Mbits/sec 14622
[ 4] 16.00-17.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 17.00-18.00 sec 114 MBytes 958 Mbits/sec 14621
[ 4] 18.00-19.00 sec 114 MBytes 958 Mbits/sec 14625
[ 4] 19.00-20.00 sec 114 MBytes 958 Mbits/sec 14622
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams
[ 4] 0.00-20.00 sec 2.22 GBytes 954 Mbits/sec 0.080 ms 8514/290998 (2.9%)
[ 4] Sent 290998 datagrams
将网卡分别绑定到vmbr1和vmbr2上
测试tcp
iperf3 -c 10.2.2.2 -t 20
结果如下
root@nettest1:~# iperf3 -c 10.2.2.2 -t 20
Connecting to host 10.2.2.2, port 5201
[ 4] local 10.2.2.1 port 47682 connected to 10.2.2.2 port 5201
[ ID] Interval Transfer Bandwidth Retr Cwnd
[ 4] 0.00-1.00 sec 116 MBytes 970 Mbits/sec 0 1.85 MBytes
[ 4] 1.00-2.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 2.00-3.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 3.00-4.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 4.00-5.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 5.00-6.00 sec 112 MBytes 942 Mbits/sec 0 1.85 MBytes
[ 4] 6.00-7.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 7.00-8.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 8.00-9.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 9.00-10.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 10.00-11.00 sec 112 MBytes 942 Mbits/sec 0 1.85 MBytes
[ 4] 11.00-12.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 12.00-13.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 13.00-14.00 sec 112 MBytes 942 Mbits/sec 0 1.85 MBytes
[ 4] 14.00-15.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 15.00-16.00 sec 112 MBytes 942 Mbits/sec 0 1.85 MBytes
[ 4] 16.00-17.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 17.00-18.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 18.00-19.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
[ 4] 19.00-20.00 sec 112 MBytes 941 Mbits/sec 0 1.85 MBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bandwidth Retr
[ 4] 0.00-20.00 sec 2.20 GBytes 943 Mbits/sec 0 sender
[ 4] 0.00-20.00 sec 2.19 GBytes 942 Mbits/sec receiver
udp测试
root@nettest1:~# iperf3 -c 10.2.2.2 -t 20 -u -b 1024m
Connecting to host 10.2.2.2, port 5201
[ 4] local 10.2.2.1 port 37418 connected to 10.2.2.2 port 5201
[ ID] Interval Transfer Bandwidth Total Datagrams
[ 4] 0.00-1.00 sec 113 MBytes 944 Mbits/sec 14412
[ 4] 1.00-2.00 sec 122 MBytes 1.03 Gbits/sec 15656
[ 4] 2.00-3.00 sec 122 MBytes 1.02 Gbits/sec 15608
[ 4] 3.00-4.00 sec 121 MBytes 1.02 Gbits/sec 15505
[ 4] 4.00-5.00 sec 123 MBytes 1.03 Gbits/sec 15736
[ 4] 5.00-6.00 sec 121 MBytes 1.02 Gbits/sec 15508
[ 4] 6.00-7.00 sec 122 MBytes 1.02 Gbits/sec 15632
[ 4] 7.00-8.00 sec 122 MBytes 1.02 Gbits/sec 15615
[ 4] 8.00-9.00 sec 122 MBytes 1.02 Gbits/sec 15629
[ 4] 9.00-10.00 sec 122 MBytes 1.02 Gbits/sec 15625
[ 4] 10.00-11.00 sec 122 MBytes 1.02 Gbits/sec 15625
[ 4] 11.00-12.00 sec 122 MBytes 1.02 Gbits/sec 15621
[ 4] 12.00-13.00 sec 123 MBytes 1.03 Gbits/sec 15725
[ 4] 13.00-14.00 sec 121 MBytes 1.02 Gbits/sec 15517
[ 4] 14.00-15.00 sec 122 MBytes 1.02 Gbits/sec 15615
[ 4] 15.00-16.00 sec 122 MBytes 1.03 Gbits/sec 15644
[ 4] 16.00-17.00 sec 122 MBytes 1.02 Gbits/sec 15631
[ 4] 17.00-18.00 sec 122 MBytes 1.02 Gbits/sec 15621
[ 4] 18.00-19.00 sec 123 MBytes 1.03 Gbits/sec 15683
[ 4] 19.00-20.00 sec 122 MBytes 1.02 Gbits/sec 15564
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bandwidth Jitter Lost/Total Datagrams
[ 4] 0.00-20.00 sec 2.37 GBytes 1.02 Gbits/sec 0.081 ms 262185/263064 (1e+02%)
[ 4] Sent 263064 datagrams
iperf Done.
版权声明:
作者:佛西
链接:https://foxi.buduanwang.vip/virtualization/1828.html/
文章版权归作者所有,未经允许请勿转载
如需获得支持,请点击网页右上角
作者:佛西
链接:https://foxi.buduanwang.vip/virtualization/1828.html/
文章版权归作者所有,未经允许请勿转载
如需获得支持,请点击网页右上角
THE END
1
二维码
海报
网卡直通性能和桥接性能对比
一 实验环境
硬件环境:
主板:NF5270M3
网卡:I350 *2 firmware-version: 1.61
CPU: E5-2670 v2
软件环境:
Proxmox VE 7.2 with kernel 5.15.30-2-pve
VM:……
文章目录
关闭
共有 0 条评论