4 ms·
There is an elephant in the room. btrfs filesystem defrag -r / You can't do that with ZFS. People can really hurt you with that. https://www.usenix.org/sy
by chasil 5y ago
There is an elephant in the room.
btrfs filesystem defrag -r /
You can't do that with ZFS.
People can really hurt you with that.
https://www.usenix.org/system/files/login/articles/login_summer17_02_conway.pdf https://www.usenix.org/system/files/login/articles/login_sum...
- pmarreck 5y ago"Git aging workload on btrfs on HDD. The overall slowdown is 20.6x." Well, this article is fascinating, but maybe the reason why btrfs has built-in defrag functionality is because without it, performance degrades incredibly steeply?
- infogulch 5y agoInteresting. That was specifically tested on ZFS in a prior paper referenced by that one and published in 2017: https://www.usenix.org/system/files/conference/fast17/fast17-conway.pdf https://www.usenix.org/system/files/conference/fast17/fast17... Glancing through, it seems ZFS is about middle of the pack of the analyzed filesystems (BetrFS Btrfs ext4 F2FS XFS ZFS) in terms of performance aging caused by change history. And only BetrFS did not show any aging from these tests and was surprisingly stable throughout. I'm curious if that's changed in recent versions of any the analyzed file systems, I know ZFS has had a major release recently.
- benjamir 5y agoWhen a comment is worth more than the discussed random blog entry... Thanks for the USENIX link!
- Dylan16807 5y agoI can't usually do that on Btrfs either. Whenever it defragments something that's COW, it makes a new copy with 1 use, and leaves all the other snapshots/reflinks pointing at the old copy.
- the8472 5y agoYou can defrag and then run an offline dedup to restore CoW.
- Dylan16807 5y agoCan I be reasonably sure that the dedup will pick the defragmented version?
- the8472 5y agoWell, most of dedup runs in userspace. But yes, the existing tools are good enough at it to work across snapshots.
- curt15 5y agoZFS has a `recordsize` parameter that can mitigate fragmentation if tuned correctly for the workload. This allows zfs to perform pretty competitively on workloads that would cripple btrfs unless one disabled copy-on-write (and therefore checksumming and compression) altogether [1]. [1] https://www.percona.com/blog/mysql-zfs-performance-update/ https://www.percona.com/blog/mysql-zfs-performance-update/