Kyle VanBenthuysen's picture

I created a bridged LXC Container from the document section on the Github page and the container will not get an ip address. When starting the container I saw the following network error: Configuring network interfaces...udhcpc: SIOCGIFINDEX: No such device
Failed to bring up eth0.

I am assuming is the root cause as to why it will not obtain an ip address.

Please let me know if there is any more information you need. 

Thank you


Jeremy Davis's picture

TBH I don't have much experience working with our LXC host appliance, but I'm assuming you are referring to this doc page?

If so, then AFAIK, it should "just work"...

Or did you mean that you are trying to launch a TurnKey LXC container on some other LXC host? If that's the case, then that's probably expected behaviour. Our LXC host appliance is tweaked a fair bit and contains some helper scripts that other LXC hosts wouldn't. So if you are using TurnKey containers on some other LXC host, I suggest that you consult their documentation on launching a container. Please note you will need to log in via SSH (using root and the root password you set when launching your LXC container) to initialise your TurnKey instance.

Kyle VanBenthuysen's picture

Yes that is the doc page I referred to. And Yes it is the TurnKey LXC Host with a TurnKey Wordpress LXC container launched from the scripts on the doc page. 

Jeremy Davis's picture

Can you please provide some additional info on where you have the LXC host appliance running? As noted in the docs, if it's running within VirtualBox (and that is configured to use bridged networking) it may give issues.

Failing that being the issue, I'm not really sure what to check next. It is unclear to me from the error message whether the real issue is with the host or the guest (although TBH I'm guessing the guest).

Looking at the code I can see that eth0 is hardcoded in a number of places. It's probably worth doing some tests on the host appliance to see if everything is ok there first. Something like the following will simply attempt tp restart the eth0 interface:

ifdown eth0 && ifup eth0

Note: if you are connected via SSH (and it's currently using eth0) then it will most likely automatically disconnect you in the process. If so (and assuming that the commands work as I expect them to) you should be able to log straight back in. Worst case scenario a reboot should resolve it.

Additional note: if your LXC host appliance is getting it's IP address via DHCP then the IP address may change during this process.

If that gives errors then it may be worth inspecting your interfaces file to see what is configured there.

cat /etc/network/interfaces

Add new comment