[lxc-users] DHCP or static ip address?

Jeff Kowalczyk jeff.kowalczyk at gmail.com
Thu Mar 2 19:53:42 UTC 2017


Static IP via DHCP reservations for LXD managed dnsmasq seems to be
manageable:

lxc network create networkname ipv4.address="10.0.1.1/24" ipv4.nat=true
ipv6.address=none
lxc network attach-profile networkname default eth0
lxc init xenial containername
lxc network attach networkname containername eth0
lxc config device set containername eth0 ipv4.address 10.0.1.10
lxc start containername

On Thu, Mar 2, 2017 at 11:32 AM, Yuri Kanivetsky <yuri.kanivetsky at gmail.com>
wrote:

> Hi,
>
> From what I can see
>
> https://github.com/lxc/lxc/blob/lxc-2.0.7/templates/lxc-ubuntu.in#L104
>
> LXC container by default expects to find DHCP server somewhere on the
> network. Which makes me think if I should set up one, which might be
> not easy. Or switch container to static ip after creation.
>
> What do you say?
>
> Regards,
> Yuri
> _______________________________________________
> 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/20170302/b4d583fa/attachment.html>


More information about the lxc-users mailing list