Details
-
Improvement
-
Resolution: Fixed
-
Minor
-
None
-
9223372036854775807
Description
The current "-o discard" mount option for ldiskfs enables on-the-fly TRIM of underlying flash devices (or thinly-provisioned LUNs). However, the current implementation hurts performance because it is done synchronously in the context of the JBD2 commit thread as a commit callback, which blocks later transaction commits.
There are patches by Shilong that make the TRIM state for a block group persistent, so that running TRIM with mke2fs does not also lead to fstrim resubmitting TRIM requests for all of the groups again immediately after mount/remount.
Most recent e2fsprogs patches at:
https://patchwork.ozlabs.org/project/linux-ext4/patch/1590588525-29669-1-git-send-email-wangshilong1991@gmail.com/
https://patchwork.ozlabs.org/project/linux-ext4/patch/1590588525-29669-2-git-send-email-wangshilong1991@gmail.com/
ext4 kernel patch:
https://patchwork.ozlabs.org/project/linux-ext4/patch/1592831677-13945-1-git-send-email-wangshilong1991@gmail.com/
https://patchwork.ozlabs.org/project/linux-ext4/patch/1592835419-7841-1-git-send-email-wangshilong1991@gmail.com/
I think the combination of these two patches would improve ongoing ldiskfs performance on flash devices significantly.
"Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/c/fs/lustre-release/+/59312/
Subject:
LU-14712ldiskfs: keep EXT4_BG_TRIMMED flag in memoryProject: fs/lustre-release
Branch: master
Current Patch Set:
Commit: ebb7c944a0115852fdcb0b32b078aed28292b054