HomeFreeBSD

System-wide speculative prefetch limit.

Description

System-wide speculative prefetch limit.

With some pathological access patterns it is possible to make ZFS
accumulate almost unlimited amount of speculative prefetch ZIOs.
Combined with linear ABD allocations in RAIDZ code, it appears to
be possible to exhaust system KVA, triggering kernel panic.

Address this by introducing a system-wide counter of active prefetch
requests and blocking prefetch distance doubling per stream hits if
the number of active requests is higher that ~6% of ARC size.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Alexander Motin <mav@FreeBSD.org>
Sponsored by: iXsystems, Inc.
Closes #14516

Details

Provenance
mavAuthored on Mar 1 2023, 11:27 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Mar 2 2023, 10:37 PM
Parents
rGb644a45bd4cd: Prefetch on deadlists merge
Branches
Unknown
Tags
Unknown

Event Timeline