[SOLVED] LXC + NetworkManager + firewalld = wrong interface to zone binding

Alexey Pavlyuts

Active Member
Jun 16, 2018
17
1
43
52
Hi All,

PVE controls LXc network interface tight by manage interface files. This leads to NetworkManaget takes config from files, and it is OK until firewalld used inside LXC.

The problem, found in Centos 7 (and posible others RHEL-based) that firewalld binds NetworkManager controlled interface to defailt firewall zone on boot, regardless of what configured in firewalld. In the regular install, it may be fixed by including ZONE=zonename option in the intrface file. But PVE rewrites these files on reboot and this solution can't survive reboot.

The question is if it possible to add some extra options to LXE network config of RHEL containers? Any extra file, like used to add routes? I see workaround to use address range for zone definition instead of interface. Or use PVE firewall instead if firewalld inside container. But for some reason I prefer to keep firewall inside LXC.

Any ideas?
 
you're welcome. please mark the thread as [SOLVED], so others running into the same issue know what to expect :)
 

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!