[Lxc-users] disk limit?

Corin Langosch corinl at gmx.de
Thu May 19 09:52:21 UTC 2011


On 19.05.2011 11:18, Ulli Horlacher wrote:
>
> But the underlaying partion must be big enouigh to contain all LXC
> containers! How do you prevent to a single container to allocate all free
> disk space?

I had no time to consult the man pages or to just give it try. Have you 
tried it? But I guess each snapshot can grow to the maximum size of the 
underlying volume, no matter how big other snapshots have grown.

Initial setup:
disc: 500 GB (one big lvm partition)
lvm volume: 10 GB (has vserver base system installation)
= free space on disk: 490 GB

Now you can create snapshots of this lv volume. When just created they 
will have no disk usage at all.

disc: 500 GB (one big lvm partition)
lvm volume: 10 GB (has vserver base system installation)
snapshot 1: 0 GB (no individual data written so far)
snapshot 2: 0 GB (no individual data written so far)
snapshot 3: 0 GB (no individual data written so far)
= free space on disk: 490 GB

After some time users install data on their vservers and so the 
snapshots grow over time.

disc: 500 GB (one big lvm partition)
lvm volume: 10 GB (has vserver base system installation)
snapshot 1: 5 GB (a lot of individual data written so far)
snapshot 2: 10 GB (ups, no space left on device)
snapshot 3: 1 GB (not so much individual data written so far)
= free space on disk: 474 GB

Otherwise Serge's suggestion wouldn't make any sense to me.

Corin





More information about the lxc-users mailing list