![](https://seccdn.libravatar.org/avatar/37ce46f3bb7af09b1da428d24b87bd4a.jpg?s=120&d=mm&r=g)
On Thu, Mar 17, 2016 at 7:38 AM, Anton Aylward <opensuse@antonaylward.com> wrote:
When I mkfs a file system I can set the block size. I can set other things depending on the file system Linda did a very good illustration of this for XFS, how the block size and make best use of the partition, waste the least amount of space. Different types of file can profit from different block sizes or extents. I thin Linda made this point talking of how videos are stored differently from the kind of files you'll find in {/usr,}/bin and {/usr,}/lib.
At the moment in Btrfs block size is fixed to kernel+arch page size, so on x86 that's a 4096 block and on PPC it's a 16KiB block. There is a different thing on Btrfs called a node (also leaf but now they're basically merged terms), and it's possible to set the nodesize at mkfs time. The old default was 4KiB, the current default for maybe two years now is 16KiB. This affects the effeciency of packing keys into the nodes, as well as ability to store inline data rather than using extents. So small files will actually have their data packed right next to their metadata in the node rather than being referenced elsewhere on the disk in a data extent. There are compression options. These can be per file or directory using an xattr if you want. There are a great many things Btrfs is poised to be able to do if you check out the features page, including per subvolume raid levels. And there's subvolume quotas which are immensely easier to figure out compared to XFS project quotas; but I have to say they're on their 3rd revision and it's not yet proven stable yet so it'll need more baking time. But it exists. Feel free to test it! A recent RFC patch was sent for per subvolume encryption, just in the last couple weeks. This is not about which file system is better it's which which one achieves your goals right now. It's a bit time consuming to migrate to a new file system but that's about it. So if Btrfs is not for you, you can use XFS now and maybe some other year Btrfs will have a feature you need that doesn't exist elsewhere.
But when you mkfs a BtrFS its homogeneous. You've made the point, I've made the point,, others have made the point, that the files under a subvolume are all made up of blocks from the same "pool", that is the same - as I use the term - 'granularity'.
Perhaps its more than a difference in use of terms, but if so I need a better explanation of how to set up subvolumes.
There's no actual need to use them. On the Btrfs list a number of users don't use subvolumes or snapshots at all. -- Chris Murphy -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org