[Lxc-users] [PATCH] Cgroup cleanups: play more nicely with others, and support nesting
Serge Hallyn
serge.hallyn at canonical.com
Fri Dec 9 21:10:23 UTC 2011
Quoting Derek Simkowiak (derek at simkowiak.net):
> Serge,
> Could you please elaborate on this comment?
>
> (Of course, the containers must be on a different subnet)
>
>
> Do you mean a TCP/IP subnet? If so, why does this limitation exist?
No I just mean that you have to make sure to use different addresses
for the bridges and all the containers :) If you use lxc in ubuntu
precise, it by default creates the following bridge:
LXC_BRIDGE="lxcbr0"
LXC_ADDR="10.0.4.1"
LXC_NETWORK="10.0.4.0/24"
LXC_DHCP_RANGE="10.0.4.2,10.0.4.254"
LXC_DHCP_MAX="253"
You have to change that in the nested container. Just as you would with
nested libvirt. So on my host I left it as above, and in the first
container (*for* the containers it nested) I changed it to 10.0.5.x.
-serge
> I would like to use nested LXC containers for reselling CPU, disk,
> and network at a data center. (I.e., my customers re-sell their CPU,
> disk, and network to their customers by using nested LXC containers.)
>
> In that scenario, all LXC containers (incl. nested ones) would need
> to be on the same subnet (because that's how the data center sells
> cabinets).
That's fine, just avoid conflicts :)
-serge
More information about the lxc-users
mailing list