root@OPNsense:~ # speedtest -s 43030 Speedtest by Ookla Server: Init7 AG - Winterthur (id: 43030) ISP: Init7 Idle Latency: 6.85 ms (jitter: 0.15ms, low: 6.74ms, high: 7.06ms) Download: 9432.59 Mbps (data used: 10.3 GB) 25.87 ms (jitter: 34.23ms, low: 6.52ms, high: 271.92ms) Upload: 225.91 Mbps (data used: 168.6 MB) 6.80 ms (jitter: 0.11ms, low: 6.61ms, high: 7.35ms) Packet Loss: 7.5%
root@OPNsense:~ # iperf3 -c speedtest.init7.net Connecting to host speedtest.init7.net, port 5201 [ 5] local <localIP> port 41761 connected to 77.109.175.63 port 5201 [ ID] Interval Transfer Bitrate Retr Cwnd [ 5] 0.00-1.06 sec 11.1 MBytes 87.8 Mbits/sec 9 96.6 KBytes [ 5] 1.06-2.06 sec 9.25 MBytes 77.9 Mbits/sec 6 46.9 KBytes [ 5] 2.06-3.06 sec 8.12 MBytes 68.1 Mbits/sec 12 46.8 KBytes [ 5] 3.06-4.06 sec 6.50 MBytes 54.5 Mbits/sec 8 54.0 KBytes [ 5] 4.06-5.06 sec 7.38 MBytes 61.9 Mbits/sec 8 39.7 KBytes [ 5] 5.06-6.06 sec 7.38 MBytes 61.9 Mbits/sec 6 62.5 KBytes [ 5] 6.06-7.06 sec 9.00 MBytes 75.5 Mbits/sec 4 96.7 KBytes [ 5] 7.06-8.06 sec 8.62 MBytes 72.4 Mbits/sec 6 32.6 KBytes [ 5] 8.06-9.06 sec 5.38 MBytes 45.1 Mbits/sec 6 72.6 KBytes [ 5] 9.06-10.06 sec 4.88 MBytes 40.9 Mbits/sec 8 26.9 KBytes - - - - - - - - - - - - - - - - - - - - - - - - - [ ID] Interval Transfer Bitrate Retr [ 5] 0.00-10.06 sec 77.6 MBytes 64.7 Mbits/sec 73 sender [ 5] 0.00-10.07 sec 76.8 MBytes 64.0 Mbits/sec receiver iperf Done. root@OPNsense:~ #
root@OPNsense:~ # dmesg mlx5_core0: <mlx5_core> mem 0x6120000000-0x6121ffffff at device 0.0 on pci1 mlx5: Mellanox Core driver 3.7.1 (November 2021)uhub0: 4 ports with 4 removable, self powered mlx5_core0: INFO: mlx5_port_module_event:705:(pid 12): Module 0, status: plugged and enabled mlx5_core: INFO: (mlx5_core0): E-Switch: Total vports 9, l2 table size(65536), per vport: max uc(1024) max mc(16384) mlx5_core1: <mlx5_core> mem 0x611e000000-0x611fffffff at device 0.1 on pci1 mlx5_core1: INFO: mlx5_port_module_event:710:(pid 12): Module 1, status: unplugged mlx5_core: INFO: (mlx5_core1): E-Switch: Total vports 9, l2 table size(65536), per vport: max uc(1024) max mc(16384) mce0: Ethernet address: <mac> mce0: link state changed to DOWN mce1: Ethernet address: <mac> mce1: link state changed to DOWN mce0: ERR: mlx5e_ioctl:3514:(pid 37363): tso4 disabled due to -txcsum. mce0: ERR: mlx5e_ioctl:3527:(pid 37959): tso6 disabled due to -txcsum6. mce1: ERR: mlx5e_ioctl:3514:(pid 41002): tso4 disabled due to -txcsum. mce1: ERR: mlx5e_ioctl:3527:(pid 41674): tso6 disabled due to -txcsum6. mce0: INFO: mlx5e_open_locked:3265:(pid 60133): NOTE: There are more RSS buckets(64) than channels(20) available mce0: link state changed to UP root@OPNsense:~ #
root@OPNsense:~ # ifconfig mce0: flags=8863<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500 description: WAN (wan) options=7e8800a8<VLAN_MTU,JUMBO_MTU,VLAN_HWCSUM,LINKSTATE,HWRXTSTMP,NOMAP,TXTLS4,TXTLS6,VXLAN_HWCSUM,VXLAN_HWTSO> ether <mac> inet <IP> netmask 0xffffffc0 broadcast <broadcast> inet6 <ip>%mce0 prefixlen 64 scopeid 0x9 inet6 <ip> prefixlen 64 autoconf inet6 <ip> prefixlen 128 media: Ethernet 25GBase-SR <full-duplex,rxpause,txpause> status: active nd6 options=23<PERFORMNUD,ACCEPT_RTADV,AUTO_LINKLOCAL> mce1: flags=8822<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=7e8800a8<VLAN_MTU,JUMBO_MTU,VLAN_HWCSUM,LINKSTATE,HWRXTSTMP,NOMAP,TXTLS4,TXTLS6,VXLAN_HWCSUM,VXLAN_HWTSO> ether <mac> media: Ethernet autoselect <full-duplex,rxpause,txpause> status: no carrier (Cable is unplugged.) nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL> root@OPNsense:~ #
root@OPNsense:~ # netstat -QConfiguration:Setting Current LimitThread count 20 20Default queue limit 2048 10240Dispatch policy deferred n/aThreads bound to CPUs enabled n/aProtocols:Name Proto QLimit Policy Dispatch Flagsip 1 1000 cpu hybrid C--igmp 2 2048 source default ---rtsock 3 2048 source default ---arp 4 2048 source default ---ether 5 2048 cpu direct C--ip6 6 1000 cpu hybrid C--ip_direct 9 2048 cpu hybrid C--ip6_direct 10 2048 cpu hybrid C--Workstreams:WSID CPU Name Len WMark Disp'd HDisp'd QDrops Queued Handled 0 0 ip 0 12 0 58203 0 111666 169869 0 0 igmp 0 0 0 0 0 0 0 0 0 rtsock 0 0 0 0 0 0 0 0 0 arp 0 0 0 0 0 0 0 0 0 ether 0 0 2355942 0 0 0 2355942 0 0 ip6 0 1 0 1908712 0 129 1908841 0 0 ip_direct 0 0 0 0 0 0 0 0 0 ip6_direct 0 0 0 0 0 0 0 1 1 ip 0 11 0 27296 0 19571 46867 1 1 igmp 0 0 0 0 0 0 0 1 1 rtsock 0 0 0 0 0 0 0 1 1 arp 0 1 0 0 0 15 15 1 1 ether 0 0 1297838 0 0 0 1297838 1 1 ip6 0 40 0 1269620 0 201 1269821 1 1 ip_direct 0 0 0 0 0 0 0 1 1 ip6_direct 0 0 0 0 0 0 0 2 2 ip 0 13 0 16382 0 17041 33423 2 2 igmp 0 0 0 0 0 0 0 2 2 rtsock 0 0 0 0 0 0 0 2 2 arp 0 0 0 0 0 0 0 2 2 ether 0 0 1501728 0 0 0 1501728 2 2 ip6 0 0 0 1219557 0 0 1219557 2 2 ip_direct 0 0 0 0 0 0 0 2 2 ip6_direct 0 0 0 0 0 0 0 3 3 ip 0 31 0 280587 0 421365 701952 3 3 igmp 0 0 0 0 0 0 0 3 3 rtsock 0 0 0 0 0 0 0 3 3 arp 0 0 0 0 0 0 0 3 3 ether 0 0 1094476 0 0 0 1094476 3 3 ip6 0 0 0 788353 0 0 788353 3 3 ip_direct 0 0 0 0 0 0 0 3 3 ip6_direct 0 0 0 0 0 0 0 4 4 ip 0 10 0 42578 0 5656 48234 4 4 igmp 0 0 0 0 0 0 0 4 4 rtsock 0 0 0 0 0 0 0 4 4 arp 0 0 0 0 0 0 0 4 4 ether 0 0 1803388 0 0 0 1803388 4 4 ip6 0 0 0 1535915 0 0 1535915 4 4 ip_direct 0 0 0 0 0 0 0 4 4 ip6_direct 0 0 0 0 0 0 0 5 5 ip 0 35 0 57631 0 92496 150127 5 5 igmp 0 0 0 0 0 0 0 5 5 rtsock 0 0 0 0 0 0 0 5 5 arp 0 0 0 0 0 0 0 5 5 ether 0 0 1078428 0 0 0 1078428 5 5 ip6 0 1 0 1020797 0 3 1020800 5 5 ip_direct 0 0 0 0 0 0 0 5 5 ip6_direct 0 0 0 0 0 0 0 6 6 ip 0 2 0 27426 0 1041 28467 6 6 igmp 0 0 0 0 0 0 0 6 6 rtsock 0 7 0 0 0 158 158 6 6 arp 0 0 0 0 0 0 0 6 6 ether 0 0 1469570 0 0 0 1469570 6 6 ip6 0 0 0 882669 0 0 882669 6 6 ip_direct 0 0 0 0 0 0 0 6 6 ip6_direct 0 0 0 0 0 0 0 7 7 ip 0 3 0 283352 0 5797 289149 7 7 igmp 0 0 0 0 0 0 0 7 7 rtsock 0 0 0 0 0 0 0 7 7 arp 0 0 0 0 0 0 0 7 7 ether 0 0 1270934 0 0 0 1270934 7 7 ip6 0 0 0 987582 0 0 987582 7 7 ip_direct 0 0 0 0 0 0 0 7 7 ip6_direct 0 0 0 0 0 0 0 8 8 ip 0 28 0 263924 0 55582 319506 8 8 igmp 0 0 0 0 0 0 0 8 8 rtsock 0 0 0 0 0 0 0 8 8 arp 0 0 0 0 0 0 0 8 8 ether 0 0 2150278 0 0 0 2150278 8 8 ip6 0 2 0 1626537 0 68 1626605 8 8 ip_direct 0 0 0 0 0 0 0 8 8 ip6_direct 0 0 0 0 0 0 0 9 9 ip 0 10 0 50414 0 117 50531 9 9 igmp 0 0 0 0 0 0 0 9 9 rtsock 0 0 0 0 0 0 0 9 9 arp 0 2 0 0 0 323528 323528 9 9 ether 0 0 1078713 0 0 0 1078713 9 9 ip6 0 45 0 1027819 0 479 1028298 9 9 ip_direct 0 0 0 0 0 0 0 9 9 ip6_direct 0 0 0 0 0 0 0 10 10 ip 0 7 0 607 0 7940 8547 10 10 igmp 0 0 0 0 0 0 0 10 10 rtsock 0 0 0 0 0 0 0 10 10 arp 0 0 0 0 0 0 0 10 10 ether 0 0 1215919 0 0 0 1215919 10 10 ip6 0 0 0 1201173 0 0 1201173 10 10 ip_direct 0 0 0 0 0 0 0 10 10 ip6_direct 0 0 0 0 0 0 0 11 11 ip 0 58 0 12866 0 210981 223847 11 11 igmp 0 0 0 0 0 0 0 11 11 rtsock 0 0 0 0 0 0 0 11 11 arp 0 3 0 0 0 35 35 11 11 ether 0 0 958646 0 0 0 958646 11 11 ip6 0 0 0 945547 0 0 945547 11 11 ip_direct 0 0 0 0 0 0 0 11 11 ip6_direct 0 0 0 0 0 0 0 12 12 ip 0 8 0 63449 0 44365 107814 12 12 igmp 0 0 0 0 0 0 0 12 12 rtsock 0 0 0 0 0 0 0 12 12 arp 0 0 0 0 0 0 0 12 12 ether 0 0 1513917 0 0 0 1513917 12 12 ip6 0 0 0 1445402 0 0 1445402 12 12 ip_direct 0 0 0 0 0 0 0 12 12 ip6_direct 0 0 0 0 0 0 0 13 13 ip 0 6 0 409033 0 4978 414011 13 13 igmp 0 0 0 0 0 0 0 13 13 rtsock 0 0 0 0 0 0 0 13 13 arp 0 0 0 0 0 0 0 13 13 ether 0 0 1516011 0 0 0 1516011 13 13 ip6 0 90 0 1099859 0 1214 1101073 13 13 ip_direct 0 0 0 0 0 0 0 13 13 ip6_direct 0 0 0 0 0 0 0 14 14 ip 0 14 0 122522 0 29387 151909 14 14 igmp 0 0 0 0 0 0 0 14 14 rtsock 0 0 0 0 0 0 0 14 14 arp 0 0 0 0 0 0 0 14 14 ether 0 0 1011518 0 0 0 1011518 14 14 ip6 0 2 0 887967 0 4 887971 14 14 ip_direct 0 0 0 0 0 0 0 14 14 ip6_direct 0 0 0 0 0 0 0 15 15 ip 0 29 0 1339 0 205348 206687 15 15 igmp 0 0 0 0 0 0 0 15 15 rtsock 0 0 0 0 0 0 0 15 15 arp 0 0 0 0 0 0 0 15 15 ether 0 0 1046188 0 0 0 1046188 15 15 ip6 0 17 0 1001970 0 32 1002002 15 15 ip_direct 0 0 0 0 0 0 0 15 15 ip6_direct 0 0 0 0 0 0 0 16 16 ip 0 7 0 49940 0 219 50159 16 16 igmp 0 0 0 0 0 0 0 16 16 rtsock 0 0 0 0 0 0 0 16 16 arp 0 0 0 0 0 0 0 16 16 ether 0 0 1590175 0 0 0 1590175 16 16 ip6 0 2 0 1490681 0 2 1490683 16 16 ip_direct 0 0 0 0 0 0 0 16 16 ip6_direct 0 0 0 0 0 0 0 17 17 ip 0 51 0 36987 0 244222 281209 17 17 igmp 0 0 0 0 0 0 0 17 17 rtsock 0 0 0 0 0 0 0 17 17 arp 0 0 0 0 0 0 0 17 17 ether 0 0 1168584 0 0 0 1168584 17 17 ip6 0 34 0 1034189 0 158 1034347 17 17 ip_direct 0 0 0 0 0 0 0 17 17 ip6_direct 0 0 0 0 0 0 0 18 18 ip 0 56 0 242236 0 468895 711131 18 18 igmp 0 0 0 0 0 0 0 18 18 rtsock 0 0 0 0 0 0 0 18 18 arp 0 0 0 0 0 0 0 18 18 ether 0 0 1426511 0 0 0 1426511 18 18 ip6 0 0 0 1054665 0 0 1054665 18 18 ip_direct 0 0 0 0 0 0 0 18 18 ip6_direct 0 0 0 0 0 0 0 19 19 ip 0 11 0 38109 0 11074 49183 19 19 igmp 0 0 0 0 0 0 0 19 19 rtsock 0 0 0 0 0 0 0 19 19 arp 0 0 0 0 0 0 0 19 19 ether 0 0 1823691 0 0 0 1823691 19 19 ip6 0 33 0 1587650 0 41 1587691 19 19 ip_direct 0 0 0 0 0 0 0 19 19 ip6_direct 0 0 0 0 0 0 0
...Does anyone use OPNSense with their 25G line or do you have any recommendations?...
mlx5_core: INFO: (mlx5_core0): E-Switch: Total vports 9, l2 table size(65536), per vport: max uc(1024) max mc(16384)
mce0: flags=8863<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
I'm not a Mellanox expert, but you might want to look at your NIC firmware settings (are you running latest firmware update ?)
regarding the operational mode: Native NIC mode vs Switchdev SRIOV.
I tried disabling SR-IOV in Opnsense, no difference. Should I have it disabled in the BIOS as well?
Last three months I experienced major issues with a SuperMicro AM5 board and a 25Gb Intel 810 ethernet adapter, after endless debugging, two interim BIOS fixes and a new firmware update for the Intel 810 it looks like things are now mostly fixed, at least the "forced" SR-IOV mode I experienced and some other stuff that both machine and NIC BIOS/Firmware should have done but didn't.
Did you set ice_ddp_load="YES"' in /boot/loader.conf.local? Otherwise OPNsense will only use only one queue on the NIC, which limits packet processing to one core, which in most cases is not enough for 25GBit throughput.