[Lxc-users] how to use routing with LXC?

Mike debian at good-with-numbers.com
Sat Jan 8 01:39:22 UTC 2011


The instructions that I've seen for LXC suggest creating a bridge in the 
host, placing its name in lxc.network.link.

On a diskless system I have eth0 & eth1, and create the bridge on eth1.  
I can't put eth0 in a bridge, because it's the port for the NFS root.  
But when I want traffic to go from the container's port to (the host's) 
eth0, I don't see how to direct that--I don't think that's even 
possible.  It instead goes out eth1 to the next hop, where the eth0 
address isn't even routeable.

So it seems that a router configuration for LXC is what I want.  I've 
done this in Xen, using their vif-route script.  How would that work 
with LXC?




More information about the lxc-users mailing list