Btrfs Async Discard Support Looks To Be Ready For Linux 5.6
After months of work by Facebook engineers, it looks like the new async discard support for Btrfs is ready for the upcoming Linux 5.6 cycle as a win for this Linux file-system on solid-state storage making use of TRIM/DISCARD functionality.
Btrfs has been handling its DISCARD functionality synchronously during the transaction commit, but that can lead to performance issues depending upon the amount of TRIM'ing required and how the drive behaves. With this async discard support, the work is punted off the transaction commit.
By doing the SSD DISCARD work asynchronously, Facebook found on their Btrfs servers that the discarding is done more efficiently and read latencies were reduced.
This async discard implementation for Btrfs was queued into the for-next branch ahead of the upcoming Linux 5.6 merge window. So unless any nasty issues come about, this should be yet another feature of the quite frankly super-feature-packed Linux 5.6 kernel.
More details on the Btrfs async discard code can be found via this code comment.
Btrfs has been handling its DISCARD functionality synchronously during the transaction commit, but that can lead to performance issues depending upon the amount of TRIM'ing required and how the drive behaves. With this async discard support, the work is punted off the transaction commit.
By doing the SSD DISCARD work asynchronously, Facebook found on their Btrfs servers that the discarding is done more efficiently and read latencies were reduced.
This async discard implementation for Btrfs was queued into the for-next branch ahead of the upcoming Linux 5.6 merge window. So unless any nasty issues come about, this should be yet another feature of the quite frankly super-feature-packed Linux 5.6 kernel.
More details on the Btrfs async discard code can be found via this code comment.
4 Comments