mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-01 08:27:59 +00:00
zfs arc_reclaim_needed: more reasonable threshold for available pages
vm_paging_target() is not a trigger of any kind for pageademon, but rather a "soft" target for it when it's already triggered. Thus, trying to keep 2048 pages above that level at the expense of ARC was simply driving ARC size into the ground even with normal memory loads. Instead, use a threshold at which a pagedaemon scan is triggered, so that ARC reclaiming helps with pagedaemon's task, but the latter still recycles active and inactive pages. PR: kern/146410, kern/138790 MFC after: 3 weeks
This commit is contained in:
parent
74f3a46a7d
commit
7c1353491f
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=212780
@ -2161,10 +2161,10 @@ arc_reclaim_needed(void)
|
||||
return (0);
|
||||
|
||||
/*
|
||||
* If pages are needed or we're within 2048 pages
|
||||
* of needing to page need to reclaim
|
||||
* Cooperate with pagedaemon when it's time for it to scan
|
||||
* and reclaim some pages.
|
||||
*/
|
||||
if (vm_pages_needed || (vm_paging_target() > -2048))
|
||||
if (vm_paging_need())
|
||||
return (1);
|
||||
|
||||
#if 0
|
||||
|
Loading…
Reference in New Issue
Block a user