On 2018-05-03 12:14, David Favor wrote:
Mark Constable wrote:
On 5/3/18 12:42 PM, Tomasz Chmielewski wrote:
Today or yesterday, bionic image launched in LXD is not getting an IPv4 address. It is getting an IPv6 address.

If you do a "lxc profile show default" you will probably find it doesn't
have an IPv4 network attached by default. I haven't yet found a simple
step by step howto example of how to setup a network for v3.0 but in my case I use a bridge on my host and create a new profile that includes...

lxc network attach-profile lxdbr0 [profile name] eth0

then when I manually launch a container I use something like...

lxc launch images:ubuntu-core/16 uc1 -p [profile name]

Be aware there is a bug in Bionic packaging, so if you upgrade
machine level OS from any previous OS version to Bionic, LXD
networking becomes broken... so badly... no Ubuntu or LXD developer
has figured out a fix.

To avoid this, move all containers off the machine... via...

   lxc stop
   lxc copy local:cname offsite:cname

Then do a fresh Bionic install at machine level. Then install
LXD via SNAP (which is only LXD install option on Bionic).

Once done, you're good to go... Just ensure...

I'm having an issue with *new* (2018-May-02 onwards) bionic containers not getting IPv4 addresses.
Bionic containers created before 2018-May-02 are getting IPv4 just fine.

Here is how I launch *new* bionic containers:

lxc launch images:ubuntu/bionic/amd64 bionictest

Just try it yourself and see if this container is getting an IPv4 address.


1) You've setup routes for all your IP ranges to lxcbr0.

All routes are fine.


2) You've added your IPV4 address to one of...

   /etc/netplan/*
   /etc/network/interfaces

I'm talking about DHCP, not a static IP address.


Tomasz Chmielewski
https://lxadm.com
_______________________________________________
lxc-users mailing list
lxc-users@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users

Reply via email to