[lxc-users] can't have internet in lxc container

mierdatutis mi mmm286 at gmail.com
Wed Dec 14 08:57:40 UTC 2016

I have a host ubuntu with dhcp and I would like to have a ubuntu guest
container with ip fixed. I'm trying to set up the /etc/network/interface
with these conf:

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static

Also, I've modified the config file of the ubuntu lxc:

root at clusterb1:/var/lib/lxc/clusterb2# more config
lxc.include = /usr/share/lxc/config/ubuntu.common.conf
lxc.rootfs = /var/lib/lxc/clusterb2/rootfs
lxc.mount = /var/lib/lxc/clusterb2/fstab
lxc.utsname = clusterb2
lxc.arch = amd64
lxc.network.type = veth
lxc.network.flags = up
lxc.network.link = lxcbr0
lxc.network.hwaddr = 00:16:3e:90:15:39
lxc.network.ipv4 =
lxc.network.ipv4.gateway =
lxc.start.auto = 0
lxc.loglevel = 0

The problem is when I connect to guest I have ip but I can't do ping to
other ip's like host ip. I says me destitation unreachable

PING ( 56(84) bytes of data.
>From icmp_seq=1 Destination Host Unreachable
>From icmp_seq=2 Destination Host Unreachable
>From icmp_seq=3 Destination Host Unreachable

Please any help? Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20161214/552ad537/attachment.html>

More information about the lxc-users mailing list