[lxc-users] Race condition in IPv6 network configuration

Marat Khalili mkh at rqc.ru
Tue Nov 7 07:17:59 UTC 2017


> If I reboot the
> container multiple times, once I'll get lucky and the interface
> configuration happens before an RA is received, and I get a permanent
> default route and everything's fine. But it's annoying because I have
> to reboot the container multiple times before it happens.
I don't know the cause of your problem, but I also encountered some race 
in container network configuration: 
https://lists.linuxcontainers.org/pipermail/lxc-users/2017-June/013456.html 
. Since no one knows why it happens, I ended up checking container 
network configurations from a cron job and restarting resolvconf if it's 
wrong then email administrator; emailing is necessary since in my case 
some services may have already failed to start by the time configuration 
is auto-corrected. Even better solution would be to put a check in a 
systemd service with correct dependencies, but I haven't implemented it yet.

Until someone finds proper solution of your problem, I suggest you to:

1) Restart not the whole container but something smaller, like 
networking or specific interface.

2) Automate check and restart as I did.

3) Write systemd service for this if you have enough time at hand, then 
share it :)

--

With Best Regards,
Marat Khalili



More information about the lxc-users mailing list