[Lxc-users] IPv4 container in a non-IPv4 main system ?
Fajar A. Nugraha
list at fajar.net
Tue Jun 12 03:38:13 UTC 2012
On Tue, Jun 12, 2012 at 2:16 AM, Sébastien Montagne
<sebastien.montagne at gmail.com> wrote:
> Now trying to setup it correctly ;)
> Sorry for annoying you again, but I couldn't make it work...
> Maybe someone could help ?
>
>
>
> My problem :
> I can't ping my gateway 91.121.99.254 from my container 91.121.99.167.
> In host I try to tcpdump pings from container, but nothing interesting is
> listed.
> I tried to add a specific host route to host 91.121.99.254 in container. The
> command works, but still can't ping it.
>
> # ping 91.121.99.254
> PING 91.121.99.254 (91.121.99.254) 56(84) bytes of data.
> From 91.121.99.167 icmp_seq=1 Destination Host Unreachable
> From 91.121.99.167 icmp_seq=2 Destination Host Unreachable
> From 91.121.99.167 icmp_seq=3 Destination Host Unreachable
>
> # route add -host 91.121.99.254 eth0
> # ping 91.121.99.254
> PING 91.121.99.254 (91.121.99.254) 56(84) bytes of data.
> From 91.121.99.167 icmp_seq=1 Destination Host Unreachable
> From 91.121.99.167 icmp_seq=2 Destination Host Unreachable
> From 91.121.99.167 icmp_seq=3 Destination Host Unreachable
>
>
>
> Host configuration : cat /etc/network/interfaces
> auto lo
> iface lo inet loopback
>
> auto br0
> iface br0 inet6 static
> bridge_ports eth0
> bridge_fd 0
> address 2001:41d0:1:98a7::1
> netmask 64
> gateway 2001:41d0:1:98FF:FF:FF:FF:FF
>
> Container configuration : grep network config
> lxc.network.type = veth
> lxc.network.flags = up
> lxc.network.link = br0
> lxc.network.name = eth0
> lxc.network.hwaddr = 00:1C:C0:17:8B:44
> lxc.network.ipv4 = 91.121.99.167/24
First of all, make sure the host's link actually works. The easiest
way is to put the guest's IPv4 address on host's eth0 (if without
bridge) or br0 (if the bridge is active).
Next, do:
- "brctl show" on the host
- "netstat -nr" on the guest
- "tcpdump -n -i eth0 host 91.121.99.254" on the guest and the host,
and "tcpdump -n -i br0 host 91.121.99.254" on the host, to see where
the packets start gone missing.
--
Fajar
More information about the lxc-users
mailing list