Hi we have been struggling to get LXD managed LXC containers to work using the failover IP range we have with our service. The only way we could get containers to work was to route via the host machine using a virtual IP on the host. The result is huge packet loss so not workable.
For example when we bring up a container we do as per the various guides and get a virtual mac and assign it to the container. We then use the failover IP and set the gateway to the host machine but with .254 as the last octet.
we have a bridged interface on the main server which works but the containers are not able to see the gateway as above:
e.g.
lxc config device add containername eth0 nic nictype=bridged parent=br1 name=eth0
lxc config set brisant volatile.eth0.hwaddr VIRTUALMAC
Surely someone must have LXD working on OVH systems? The same setup works flawlessly on other providers. Any advice appreciated before we ditch our OVH systems and move to another one that works ![]()
The gateway should be with 254 at the end of the failover IP, rather than the host, this way if the IP is moved to another host, it will still work.
So if you have an IP failover that is 1.2.3.4 then the gateway would 1.2.3.254, regardless of the host IP.
Hi
Did you manage to make it work ?
i also avec an LCX and i would like to know if it's possible to ad more IP on the same container ans how to do that
thanks
yes all working, but in a rather convoluted way and via host routing. Rock solid though. You can add as many interfaces as you like on the containers as you would normally such as this below where br1 is your host bridge interface:
lxc config device add containername eth0 nic nictype=bridged parent=br1 name=eth0
lxc config device add containername eth1 nic nictype=bridged parent=br1 name=eth1