Experiences with x86 Openwrt on QEMU VM vs Vyos

I have an OpenWrt hardware router with extensive configuration and it works very well for me, however i need a single computer to serve as a router and application server.

The Openwrt router will be replaced wy a 10W TDP Intel computer running libvirt/QEMU, and I have two router OS in my network, OpenWrt and VyOS to choose from. What are people's experience with performance on OpenWrt x86

A) Staying with OpenWrt is all of my configuration will carry over to the new virtual router with only minor changes (setting eth ports)
B) Vyos 1.4 rolling has modern kernel and possibly better (or worse) features than OpenWrt

Benefit A is really attractive, but if there's general concensous that OpenWrt x86 has issues as a VM, switching to a proper Virtual Router OS is an option

1 Like

do your questions affect in any way the decision to move forward or this concrete purchasing decision?
If not, I would just get the hardware and then try both and then stick to the router firmware that you liked more.

"Mom, can we get some features?"
"NO! We already have features at home!"
...not sure, what you were hoping for so far. Maybe you get some opinions, if you go into detail of your router requirements...

I think, there tends to be a general consensus that there are people out there that want to use virtualized OpenWRT, but beyond that are not really into investing into gaining virtualization knowledge or into debugging virtualization issues, but instead show up here, hoping to get unexpected virtualization issues solved by this forum.
(Spoiler: The outcome is always friendly, but there is close to none virtualization knowledge around in the forum, as the broad mass is using bare metal. It can be done, but issues tend to require an virtualization-experienced layer 8 to solve them)

I run a few OpenWrt VMs in KVM/QEMU managed by libvirt.
The VMs are connected in cascade and mainly used for testing specific features.
I have not tested the performance since it is good enough to not concern me.
On the other hand, I have not noticed any particular problems either.

1 Like

hi,

  1. i am using some owrt VMs, not in production though, but had no issue so far.
  2. i think neither owrt or wyos was meant to run as vm, so no special customization/optimization has been done as i know: default use case for both is bare metal.
  3. there are different type of virtualization that can cause problems, hw vs process virtualization does have its own benefits and drawbacks. e.g. process virtualization may not work well due to missing host kernel features.
  4. QEMU can emulate hw so that could work but performance wise it depends more how host-guest interfaces (network device driver) are performing rather than owrt/wyos itself. full hw emulation always has a performance penalty.
  5. personally i don't really like the idea to have my internet facing main router running as vm because there is catch-22: host may depend on a vm to access internet but vm cannot run if host stop router vm for whatever reason (e.g. during upgrade/patching).
  6. you have not mentioned what feature you need does not exist in owrt but does in wyos. so hard to say which to pick. but probably having a working owrt config and familiarity is a big advantage imho.

so if you have chance test both and pick whichever is better for your use case.

1 Like

reply to @Pico as well

virtualization issues are not a problem for me, I've been running vyos both bare metal and virt for years.

Both OpenWrt and Vyos will meet my needs from a feature perspective, on this new application. The reason I'm moving from hardware openwrt to virtualized is because my application needs video decoding which isn't easy to do on the Mali GPU of my rockchip based openwrt.

Currently I run docker in an lxc container ontop of OpenWrt, I will be running docker on the baremetal of the new computer so they have access to the intel GPU, and the new Router will have the LAN and WAN interfaces bridged directly into it (the baremetal OS will attach to the LAN bridge via openvswitch

So ultimately staying with OpenWRT would be a convienence factor since all my router config is ready to go, including subnets, wireguard tunnels, bgp routing, etc... I could easily rebuild on Vyos in a short time, I just don't want to go through the same agony of testing and troubleshooting again.

So with all that said, the only determining factor to not use OpenWRT as a VM would be if it doesn't support virtio interfaces, or generally had poor performance/ on generic hardware, wheras mainline openwrt builds are optomized for their individual platforms

OpenWrt definitely supports VirtIO for both interfaces and disks.

In my experience, this is not the case.


To be honest, you might not even need full virtualization.
Just install the LXC driver for libvirt and create an OS-level container from the rootfs image.

4 Likes

Performance is great in VM/CT, in ran both of them but i have sticked to CT.
Virtio is supported, i use 4 nics without problems.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.