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

jjs - mainphrame jjs at mainphrame.com
Sat Apr 14 17:22:54 UTC 2018


Bump -

The bug is 100% repeatable. Steps to reproduce:

1. create ubuntu container (lxc launch)
2. enter container and configure a static IP in /etc/network/interfaces
3. If container is 16.04, only static IP exists. if container is 18.04.
there are both static and dhcp ips.

+-----------------+---------+------------------------+------+------------+-----------+
| national-dragon | RUNNING | 192.168.111.26 (eth0)  |      | PERSISTENT |
0         |
+-----------------+---------+------------------------+------+------------+-----------+
| open-moth       | RUNNING | 192.168.111.25 (eth0)  |      | PERSISTENT |
0         |
|                 |         | 192.168.111.241 (eth0) |      |            |
         |
+-----------------+---------+------------------------+------+------------+-----------+

Jake


On Sat, Apr 7, 2018 at 1:16 PM, jjs - mainphrame <jjs at mainphrame.com> wrote:

> Greetings,
>
> Running lxd-3.0.0 on ubuntu 18.04 beta
>
> I've set up a couple of new 16.04 cts and they act as I expect.
>
> I set up an 18.04 ct and a persistent unwanted dhcp IP appears in the lxc
> list:
>
> root at ronnie:~# lxc list
> +-----------+---------+------------------------+------+-----
> -------+-----------+
> |   NAME    |  STATE  |          IPV4          | IPV6 |    TYPE    |
> SNAPSHOTS |
> +-----------+---------+------------------------+------+-----
> -------+-----------+
> | dbserv111 | RUNNING | 192.168.111.221 (eth0) |      | PERSISTENT | 0
>      |
> +-----------+---------+------------------------+------+-----
> -------+-----------+
> | kangal    | RUNNING | 192.168.111.44 (eth0)  |      | PERSISTENT | 0
>      |
> |           |         | 192.168.111.239 (eth0) |      |            |
>      |
> +-----------+---------+------------------------+------+-----
> -------+-----------+
> | mg111     | RUNNING | 192.168.111.222 (eth0) |      | PERSISTENT | 0
>      |
> +-----------+---------+------------------------+------+-----
> -------+-----------+
>
> However, inside the 18.04 container (kangal), only the static IP is listed:
> root at kangal:~# ifconfig
> eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
>         inet 192.168.111.44  netmask 255.255.255.0  broadcast
> 192.168.111.255
>         inet6 fe80::216:3eff:fef3:857e  prefixlen 64  scopeid 0x20<link>
>         ether 00:16:3e:f3:85:7e  txqueuelen 1000  (Ethernet)
>         RX packets 80658  bytes 97973222 (97.9 MB)
>         RX errors 0  dropped 0  overruns 0  frame 0
>         TX packets 56964  bytes 5320056 (5.3 MB)
>         TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
>
> lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
>         inet 127.0.0.1  netmask 255.0.0.0
>         inet6 ::1  prefixlen 128  scopeid 0x10<host>
>         loop  txqueuelen 1000  (Local Loopback)
>         RX packets 1400  bytes 115581 (115.5 KB)
>         RX errors 0  dropped 0  overruns 0  frame 0
>         TX packets 1400  bytes 115581 (115.5 KB)
>         TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
>
> root at kangal:~#
>
> However I can ssh to this dhcp IP and gain access to the box.
>
> Any clues as to how to get rid of this unwanted extra IP?
>
> Jake
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20180414/267f08b5/attachment.html>


More information about the lxc-users mailing list