Re: [PATCH 0/2] Preemptive flushing fixes
From: David Sterba <hidden>
Date: 2021-08-16 14:00:50
On Wed, Aug 11, 2021 at 02:37:14PM -0400, Josef Bacik wrote:
Hello, I thought I had fixed the preemptive flushing burning CPU's problem with my previous set of fixes, but I was wrong. However those tracepoints gave me the information I needed to fix the problem properly. The first patch btrfs: reduce the preemptive flushing threshold to 90% can go back to stable and make its way into the distros to stop the pain for the current users having problems. The second patch augments the fix with a little less of a strong hammer. The problem is for very full file systems on slower disks will end up with a very small threshold to start preemptive flushing. We were relying on sanity checks to bail out ahead of time, however they were not strong enough. These problematic cases existed in the short area where there was enough space to operate without needing to do synchronous flushing, but not enough space to avoid flushing all of the time. The fix is to adjust the sanity checks to something more reasonable to account for these cases and avoid spinning doing preemptive flushing constantly. Thanks, Josef Josef Bacik (2): btrfs: reduce the preemptive flushing threshold to 90% btrfs: do not do preemptive flushing if the majority is global rsv
Added to misc-next, thanks.