[Lxc-users] Network confusion

Daniel Lezcano dlezcano at fr.ibm.com
Fri Jan 29 14:41:43 UTC 2010


Matteo Ghezzi wrote:
> Hi,
> I'm very new to lxc, I've switched from openvz and I'm testing my
> first container.
> I'm using Arch as host (192.168.0.2, kernel 2.6.32.7, and lxc-tool
> 0.6.5) and I've created a container via the lxc-debian script.
> I can start the container normally, I can access both the lan and the internet.
> In the host I've setup the bridge like reported here --> http://lxc.teegra.net/
> I've setup my hardware firewall (pfsense box) to use a secondary wan
> only for the traffic generating from this container: 192.168.0.100.
> If I check the ip from www.whatismyipaddress.com all is working
> accordingly: different IPs (1 for every wan) 1 for the container, 1
> for the Arch host.
> The problem arises in the lan.
> If I try to ssh to the container IP i got ssh access to the Arch host instead.
> Other times I can access the container:
> with an ssh connection to the server, a direct acces via lxc-start not
> demonized to the container, and links2 opened on a website in both the
> container and the host, if i restart the openssh server in the
> container i lose connection to the host, and can access the container
> IP.
> I tried changing the port of the openssh server in the container, but
> the problem is the same: i got connection refused from the host.
> 
> All suggestions are welcomed.
> Thanks.

Can you send the config file of the container ? it should be in 
/var/lib/lxc/<container_name>/config or /etc/lxc/<container_name>.

As well as the result of ifconfig in the container and outside the 
container.

thanks
  -- Daniel




More information about the lxc-users mailing list