vmbr0 is taking main interface's ip

kifeo

Well-Known Member
Oct 28, 2019
112
12
58
Hello,

I've followed the network configuration like here :
https://pve.proxmox.com/wiki/Network_Configuration at Masquerading with iptables for my lxc subnet

It worked at first, but now it does not. Here is my config :
/etc/network/interface file

Code:
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
        address a.b.c.d <<<<<<<<<<<<<<<<<<<<<<<<<<<< Here
        netmask 255.255.255.0
        gateway a.b.c.254

auto vmbr0
# private sub network
iface vmbr0 inet static
    address 10.100.0.1 <<<<<<<<<<<<<<<<<<<<<<<< here
    netmask 255.255.255.0
    bridge_ports none
    bridge_stp off
    bridge_fd 0

    post-up   echo 1 > /proc/sys/net/ipv4/ip_forward
    post-up   iptables -t nat -A POSTROUTING -s '10.100.0.0/24' -o eth0 -j MASQUERADE
    post-down iptables -t nat -D POSTROUTING -s '10.100.0.0/24' -o eth0 -j MASQUERADE

and even with a 'systemctl restart networking', the bridge does not have the correct IP :
ip a sh
Code:
<....snip.....>
73: vmbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether <edited_MACADDR> brd ff:ff:ff:ff:ff:ff
    inet a.b.c.d/24 brd a.b.c.255 scope global vmbr0 <<<<<<<<<<<<<<<<<<<<<<<<< and here
    valid_lft forever preferred_lft forever

I'm losing my mind on this one :D
Would someone please have a hint ?
Thanks !
 
I could workarounf by removing ipv6 on the bridge in sysctl.conf :
net.ipv6.conf.vmbr0.disable_ipv6 = 1

When I restart networking service, it puts correctly the configured ip to the bridge interface.

After some time, the vmbr0 interface takes back the main interface ip.

Does anyone know if proxmox is behaving like this ?
 

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!