[lxc-users] Btrfs gquota and container disk usage limits

david.andel at bli.uzh.ch david.andel at bli.uzh.ch
Sat Apr 4 16:22:31 UTC 2015


Hi Mark

I see that nobody replied to your question.
Have you made any progress in the meantime?
Also, how did you manage to have your containers v1 and v2 installed into a btrfs subvolume? With lxc-create it's clear, but with lxc launch?

Thanks,
David

-----"lxc-users" <lxc-users-bounces at lists.linuxcontainers.org> wrote: -----
To: lxc-users <lxc-users at lists.linuxcontainers.org>
From: Mark Constable 
Sent by: "lxc-users" 
Date: 03/20/2015 1:38
Subject: [lxc-users] Btrfs gquota and container disk usage limits

I've tried to see if btrfs gquota applied to the btrfs subvolumes
automatically created with both lxc-create and lxc create would
be reflected within a container via df but no such luck yet. I'm
just wondering if I am doing this right and/or any hints I may be
missing?

Or is this another thing that is not ready yet?

Ubuntu 15.04 host and containers, 1 system, 2 unprivileged lxd...

~ btrfs sub list /
ID 1674 gen 560623 top level 5 path @
ID 1675 gen 560623 top level 5 path @home
ID 2388 gen 551854 top level 1674 path var/lib/lxc/sysadm.lan/rootfs/var/lib/machines
ID 2389 gen 551882 top level 1674 path var/lib/machines
ID 2403 gen 554661 top level 1674 path var/lib/lxd/lxc/v1/rootfs/var/lib/machines
ID 2407 gen 556386 top level 1674 path var/lib/lxd/lxc/v2/rootfs/var/lib/machines

btrfs quota enable /
btrfs quota rescan /
btrfs qgroup limit 5G /var/lib/lxc/sysadm.lan/rootfs/var/lib/machines
btrfs qgroup limit 1G /var/lib/lxd/lxc/v1/rootfs/var/lib/machines
btrfs qgroup limit 5G /var/lib/lxd/lxc/v2/rootfs/var/lib/machines
btrfs quota rescan /

~ btrfs qgroup show / -re
qgroupid rfer        excl        max_rfer   max_excl
-------- ----        ----        --------   --------
0/5      16384       16384       0          0
0/930    14095704064 14095704064 0          0
0/931    60293865472 60293865472 0          0
0/1674   25438732288 25438732288 0          0
0/1675   42481688576 42481688576 0          0
0/2388   16384       16384       5368709120 0
0/2403   16384       16384       1073741824 0
0/2407   16384       16384       5368709120 0
_______________________________________________
lxc-users mailing list
lxc-users at lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20150404/569914c2/attachment.html>


More information about the lxc-users mailing list