[SOLVED] Openwrt in proxmox

generalproxuser

Active Member
Mar 14, 2021
100
28
33
44
I have tried two methods.

https://www.jwtechtips.top/how-to-install-openwrt-in-proxmox/
https://forum.openwrt.org/t/guide-run-openwrt-as-a-container-in-proxmox/44683

In the vm method openwrt does not completely boot. It gets stuck at the br-lan ready section and hangs.
In the container method the container never starts.

I have been researching and trying to get this running for about 2 months now. Does anyone possibly have any other resources that will allow me to run openwrt as a container preferably?

Many thanks.
 
HI generalproxuser,

Disclaimer, I'm fairly new to Proxmox and only trying to help where I can.

I wouldn't follow the 2nd container guide, although most commands are the same as Ubuntu, certain items (especially around networking).
Ubuntu default bridge name is br(-lan) while Proxmox is vmbr0, (1) etc. Also setting up networking in a container is far more difficult than in a VM, I would only try that if I was severity restricted in RAM resources.

2nd, consider if, after 2 months trying, you really need to deploy OpenWRT ? pfsense firewall is simple to setup in a Proxmox VM, it has a wazard to get you started with the basics, will perform the same tasks AND most importantly, is far better supported when you do run into difficulties.

Just something to consider.

DerekG
 
Derek,

Thank you for your thoughts. OpenWRT (from what I have found) has a bit more features that I want/need to use. I am familiar with containers as I have a pihole and some other small containers already running in my proxmox environment. They currently get dhcp IP off my lan so setting up their networks so far has not presented any issues to me.

Admittedly my existing containers had templates pre-existing so that made spinning them up easier.

I might have stumbled onto something that might get me what I need (openwrt in a container) though I am still testing it. Seems to always happen that way, I hit a block and ask the forum for help, and then get a "eureka" moment and start making headway again.

So far I managed to get openwrt to fully start in a container and I didn't have to bulid anything like the second link I provided. Now I am working on the networking.
 
At this point I have already achieved running openwrt in both a ct and vm and have found the vm route the better option with openwrt. Openwrt was faster and easier (for me) to configure overall especially with an openvpn server. Besides, I have a small enough home network that doesn't quite "need" 2.5 or 10GB NICs anywhere so openwrt satisfies the small\simple task of being my edge router and firewall and dhcp server while pihole serves my dns. I know pfsense has something similar to what pihole does but at this point until any of my existing items absolutely fail me I will be sticking with them.
 
  • Like
Reactions: vesalius
I would add that pfsense is run by folks that have a history of attacking and trying to sabotage other companies as well as recently making poor decisions to release code into production before it is fully vetted just to be first. If you ever feel the need to look beyond openwrt check into opnsense with the available adguard home plugin next. :cool:
 
  • Like
Reactions: generalproxuser
pfSense works perfectly for me. My reaction was to that someone said that pfSense doesn't have the same capabilities as OpenWRT. That isn't true. If you like openWRT better that is possible.
 
pfSense works perfectly for me. My reaction was to that someone said that pfSense doesn't have the same capabilities as OpenWRT. That isn't true. If you like openWRT better that is possible.

There's one big capability that OpenWRT has and pfSense does not: CAKE
It's the reason why I'm installing OpenWRT on the new box this week instead of transferring pfSense to it
 
At this point I have already achieved running openwrt in both a ct and vm and have found the vm route the better option with openwrt. Openwrt was faster and easier (for me) to configure overall especially with an openvpn server. Besides, I have a small enough home network that doesn't quite "need" 2.5 or 10GB NICs anywhere so openwrt satisfies the small\simple task of being my edge router and firewall and dhcp server while pihole serves my dns. I know pfsense has something similar to what pihole does but at this point until any of my existing items absolutely fail me I will be sticking with them.
Hi,
I am just starting with proxmox and installed my Proxmox yesterday. Now I would also like to try our openwrt VM or LXC works better and efficiently for me. I have plenty of ram. But if LXC works more efficiently then is better.

Can you kind to share the guide/resource you use to get it configured? I follow some guide/YouTube but they all show how to install openwrt but never a proper correct guide on how to set up the network part. I follow a YouTube for LXC but never able to connect to it with the given IP and can’t figure out how to setup/change the network config.

I have a miniPC with 6 Ethernet Ports. Want to use OpenWrt as secondary/bypass router. Main router will do the dhcp works
 
  • Like
Reactions: bright_plastik
@alcw Based on your description your network configuration would have to be decided by you. The reason most guides/videos/tutorials only show how to install openwrt in a vm/lxc and not the network configuration side is because that's too many variables to account for between different environments. If you can install the openwrt vm/lxc then the hard part is done and it becomes your duty to configure and manage your network configs according to your requirements.

To add, since you said you have 6 ethernet ports, you also would be in control of how you allocate those ports and in turn how it is allocated to your openwrt vm/lxc and/or proxmox host.
 
Last edited:
Indeed don't understand the need for lxc, what difference does it make ? Yes the vm can have the resource to pass pci device, but as we don't used that.. it should be quite transparent ? As to set it, it's quite easy: your vmNetwork on as nic2 being the wan. And nic 1 a random new vswith that act as a hub and you plug your vm on it.
 
In this thread https://forum.proxmox.com/threads/openwrt-lxc-installation-error.106991/ I talked about what I found when running openwrt in lxc. If none of the issues I found (at that time) concern you then it comes down to personal preference if you want to use lxc or vm.

I have 10 ports on one my proxmox servers (2 pcie 4port cards and 2 on-board) and they are cut up in a way that suits my needs and are exposed to my openwrt vm but not as passthrough. They are configured as linux bonds because the switch they are connected to is configured as LACP/LAG trunks. Openwrt only sees them as one "physical" interface. This, again, is why I stated that your network setup is completely up to you to manage.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!