]> granicus.if.org Git - zfs/commitdiff
Added recalculation of ARC stats mid-eviction
authorRich Ercolani <Rincebrain@gmail.com>
Wed, 5 Sep 2018 05:15:14 +0000 (01:15 -0400)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Wed, 5 Sep 2018 05:15:14 +0000 (22:15 -0700)
Re-adds a recalculation step for the ARC stats after the MRU
eviction so that we don't pathologically attempt to evict the MFU.

Reviewed-by: Richard Elling <Richard.Elling@RichardElling.com>
Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Authored-by: Mark Johnston <markj@freebsd.org>
Signed-off-by: Rich Ercolani <rincebrain@gmail.com>
Closes #7855

module/zfs/arc.c

index 727b21f3fcb96c48cf2a11b0954bd95de4dee213..5e53f987961af1585edb0b5959dc23b6b5bdba09 100644 (file)
@@ -4638,6 +4638,13 @@ arc_adjust(void)
                    arc_adjust_impl(arc_mru, 0, target, ARC_BUFC_METADATA);
        }
 
+       /*
+        * Re-sum ARC stats after the first round of evictions.
+        */
+       asize = aggsum_value(&arc_size);
+       ameta = aggsum_value(&arc_meta_used);
+
+
        /*
         * Adjust MFU size
         *