I have a 10G fiber line (XGS-PON) and ran OPNsense as a VM on Proxmox. Routing between two VLANs topped out at about 8.5 Gbit/s for a single TCP stream, with all 4 vCPUs at 100 %. Since I’m thinking about a 25G line, I switched the router VM to OpenWrt.

Same host, same NICs (Mellanox ConnectX-4, SR-IOV virtual functions at the time), iperf3 across VLANs through the router:

  • OPNsense: 8.49 Gbit/s single stream, 9.37 with more streams, 4 cores maxed
  • OpenWrt: 15.1 Gbit/s single stream at about 1.2 cores, 17.9 Gbit/s with 8 streams at about 1.8 cores (software flow offloading)

Upload to the internet, single stream: 4.07 Gbit/s on OPNsense (5.1 to 5.3 after a lot of TX ring tuning), 7.54 Gbit/s with 0 retransmits on OpenWrt without any tuning. 7.6 Gbit/s is the limit of my ONT anyway.

Things I learned on the way:

  • NethSecurity (OpenWrt based) has no mlx5 driver in its feed, and the upstream module doesn’t load because the kernel config differs. With Intel cards it would have been an option.
  • On OpenWrt, busybox top and shell arithmetic overflow on byte counters above 4 GB. At 15 Gbit/s they showed “0 Mbit/s, 100 % idle”. Use proper tools for measuring.
  • LuCI covers everything I used in OPNsense, except that I had to give up NTS (plain NTP is fine for me).

Since then I moved from SR-IOV to virtio and the numbers changed a bit, but the router is no longer the bottleneck. Anyone else running OpenWrt as a VM router at 10G or more? I’d be curious what you see with Intel NICs.

  • Smash@lemmy.self-hosted.site
    link
    fedilink
    arrow-up
    1
    ·
    3 hours ago

    You had some serious misconfiguration going on. Probably wrong settings for hardware offloading, flow control, CPU flags or VirtIO I only use OpenWRT on my 2,5GbE router and 10GbE with OPNsense on proxmox, almost 0% CPU utilization under full load.

      • tofu@lemmy.nocturnal.garden
        link
        fedilink
        arrow-up
        1
        ·
        25 minutes ago

        Yeah it has already been answered. It was an honest question, I’ve never used OpenWRT and just roughly know it’s a router os.

    • Jimbambuli@lemmy.worldOP
      link
      fedilink
      arrow-up
      2
      ·
      5 hours ago

      Yes, the normal firewall ruleset was active during the tests, the traffic crossed two firewall zones. Software flow offloading only speeds up connections that the rules have already allowed.