On Tue, 2022-02-08 at 13:56 +0100, Peter Boy wrote:
On the other hand, the traditional approach has only a poor solution to restrict directories. At installation time, the harddisk can be partitioned so that every directory (eg. /usr, /var/, ...) that needs a limit gets its own partition. The obvious problem is that those limits cannot be changed without a reinstallation. The btrfs subvolume feature builds a bridge. Subvolumes correspond in many ways to partitions, as every subvolume looks like its own filesystem. With subvolume quota, it is now possible to restrict each subvolume like a partition, but keep the flexibility of quota. The space for each subvolume can be expanded or restricted on the fly.
The quote describes a situation which has gone for more of a decade now. Since we have LVM (when got that part of the Linux kernel? kernel 2.6? 2004 or so? Don’t know exactly), no one would partition a hard disk along file system subdirectories. You create logical volumes instead, which can easily "changed without a reinstallation“ and space for any logical volume "can be expanded or restricted on the fly“. The latter even easier with „thin provisioning“. And of course you can do backups and restores via snapshot, it's called LVM snapshot. What a surprise.
I've been using BTRFS for several years now and it suits me. I could never get my head around LVM and considered it overkill for what most workstation users need, but that's a matter of personal taste.
poc