[lxc-users] [Solved] Re: How to get rid of pesky extra dhcp IP

jjs - mainphrame jjs at mainphrame.com
Fri Apr 20 16:40:12 UTC 2018


Thanks for the additional info and pointers.

BTW I'd noticed that the ip command showed the extraneous IP missed by
ifconfig. But not showing the extra IP was not the problem, rather that the
extra IP existed at all. In any event, the removal of netplan and cloud
packages facilitate the intended modes of operation in my environment
(system type containers using bridged networking and static IPs)

But I do prefer to see the whole system work as intended, so thanks for the
netplan details.

BTW - re your recommendation to install LXD via snap - is the preferred
install method moving forward?

Jake

On Thu, Apr 19, 2018 at 8:13 AM, David Favor <david at davidfavor.com> wrote:

> jjs - mainphrame wrote:
>
>> Thanks for the insights. The netplan and cloud packages look like
>> something which might be indeed useful in uses cases other than mine.
>> In retrospect I'm curious how 16.04 is working so well without netplan.
>> Apparently further study is needed...
>>
>
> Netplan support begins with Artful (where Netplan + old style EIN coexist).
>
> Netplan is default in Bionic... well sort of default Artful too.
>
> My suggestion is when Bionic releases in a few days, start with a fresh
> system.
>
> 1) Install Bionic from scratch at machine level. No update, true install.
>
> 2) Install LXD via snap. No migration, true install.
>
> 3) Do an lxd copy remote:cname local:cname for each container, to move them
>    from where ever they live to your Bionic machine.
>
> The /etc/netplan/60-public-init.yaml file format I've been using, which
> works...
>
> network:
>    version: 2
>    ethernets:
>       eth0:
>          match:
>             name: eth0
>          addresses:
>          - X.X.X.X/32
>
> The Netplan docs are... to me... are overly complex + difficult to
> understand.
>
> For example, the eth0: above requires the match: operator (I guess) to
> differentiate
> between base interface name + aliases.
>
> Just start with the above Netplan config file + get your system working,
> then start
> making whatever experimental changes seem useful.
>
> Netplan is very unforgiving + in many cases syntax errors emit no
> errors/warnings,
> so you have to do eyeball syntax checking.
>
> Jake
>>
>> On Mon, Apr 16, 2018 at 6:13 AM, David Favor <david at davidfavor.com
>> <mailto:david at davidfavor.com>> wrote:
>>
>>     jjs - mainphrame wrote:
>>
>>         Confirmed, removing netplan solves the problem.
>>
>>         Thanks for the hint.
>>
>>         Jake
>>
>>         On Sat, Apr 14, 2018 at 10:39 AM, jjs - mainphrame
>>         <jjs at mainphrame.com <mailto:jjs at mainphrame.com>
>>         <mailto:jjs at mainphrame.com <mailto:jjs at mainphrame.com>>> wrote:
>>
>>             Thanks for the clue. Looking into this.
>>
>>             Jake
>>
>>             On Sat, Apr 14, 2018 at 10:31 AM, Sergiusz Pawlowicz
>>             <sergiusz at pawlowicz.name <mailto:sergiusz at pawlowicz.name>
>>         <mailto:sergiusz at pawlowicz.name
>>         <mailto:sergiusz at pawlowicz.name>>> wrote:
>>
>>                 it's not a bug, it is a feature
>>
>>                 man netplan
>>
>>
>>     Netplan doesn't get rid of the "pesky DHCP IP".
>>
>>     Currently there's a bug in ifconfig, which fails to report the DHCP
>> IP.
>>
>>     The only way (till the ifconfig bug is fixed) you can view all IPs
>>     via...
>>
>>        ip addresses (container level)
>>
>>        lxc list     (machine level)
>>
>>     Likely good for you to read many posts about the purpose of the DHCP
>> IP
>>     inside containers.
>>
>>     If you do destroy this IP (in netplan - rm -f /etc/netplan/50*), then
>>     you'll produces subtle packet routing breakage when trying to
>>     communicate
>>     between containers (yes even if they have public IPs).
>>
>>     _______________________________________________
>>     lxc-users mailing list
>>     lxc-users at lists.linuxcontainers.org
>>     <mailto:lxc-users at lists.linuxcontainers.org>
>>     http://lists.linuxcontainers.org/listinfo/lxc-users
>>     <http://lists.linuxcontainers.org/listinfo/lxc-users>
>>
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> lxc-users mailing list
>> lxc-users at lists.linuxcontainers.org
>> http://lists.linuxcontainers.org/listinfo/lxc-users
>>
> _______________________________________________
> lxc-users mailing list
> lxc-users at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20180420/db81cb70/attachment.html>


More information about the lxc-users mailing list