4 ms·
Overhead seems to be about 4KiB, at least using default ext4 parameters: # zfs create -V 100G -b 4096 tank/test && mkfs.ext4 -v /dev/zvol/tank/test && mount
by quantumofalpha 5y ago
Overhead seems to be about 4KiB, at least using default ext4 parameters:
# zfs create -V 100G -b 4096 tank/test && mkfs.ext4 -v /dev/zvol/tank/test && mount /dev/zvol/tank/test /mnt && cd /mnt
# df -k .
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/zd16 102626232 24 97366944 1% /mnt
# for x in `seq 1000000`; do echo $x >$x; done # create 1M tiny files
# df -k .
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/zd16 102626232 4022348 93344620 5% /mnt
# bc -l
(97366944-93344620)*1024/1000000 # free space diff per file
4118.859776
Plus you're wasting an inode per record - a limited resource in ext4, increasing which requires reformatting. You'd probably run out of inodes much sooner than out of space.
- fulafel 5y agoInteresting, indeed the inline data option is not enabled even by the latest e2fsprogs even though the feay has been there a long time. Re inodes, this is a good point too. These definitely reduce the size of db that fs works nicely for.