From 0045fc11063e0a7b2d002027292f0e1cca805cea Mon Sep 17 00:00:00 2001 From: bugclerk <40872210+bugclerk@users.noreply.github.com> Date: Fri, 28 Jun 2024 11:37:28 -0700 Subject: [PATCH] Tune ARC memory pressure parameters (#13951) - Setting zfs_arc_shrinker_limit=0 should make ARC more obedient to all kernel shrinker KPI requests, that should help to avoid OOMs. - zfs_arc_pc_percent=300 should prevent file-backed part of page cache from getting bigger than 1/3 of ARC, that should help with ARC shrinking to its minimum by heavy mmap() I/O. It is not perfect from perspective of adapting to different workloads, but the best we can do for now. (cherry picked from commit 29746fae59276add9f9af1acbd19e3a75eb0881f) Co-authored-by: Alexander Motin --- src/freenas/usr/lib/modprobe.d/truenas.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/freenas/usr/lib/modprobe.d/truenas.conf b/src/freenas/usr/lib/modprobe.d/truenas.conf index d5cae8458af72..236454db9609a 100644 --- a/src/freenas/usr/lib/modprobe.d/truenas.conf +++ b/src/freenas/usr/lib/modprobe.d/truenas.conf @@ -1,3 +1,3 @@ options spl spl_panic_halt=1 -options zfs zfs_default_ibs=15 +options zfs zfs_default_ibs=15 zfs_arc_shrinker_limit=0 zfs_arc_pc_percent=300 blacklist irdma