HomeFreeBSD

Prune metadata from ghost lists in arc_adjust_meta

Description

Prune metadata from ghost lists in arc_adjust_meta

To maintain a strict limit on the metadata contained in the arc, while
preventing the arc buffer headers from completely consuming the
"arc_meta_used" space, we need to evict metadata buffers from the arc's
ghost lists along with the regular lists.

This change modifies arc_adjust_meta such that it more closely models
the adjustments made in arc_adjust. "arc_meta_used" is used similarly to
"arc_size", and "arc_meta_limit" is used similarly to "arc_c".

Testing metadata intensive workloads (e.g. creating, copying, and
removing millions of small files and/or directories) has shown this
change to make a dramatic improvement to the hit rate maintained in the
arc. While I think there is still room for improvement, this is a big
step in the right direction.

In addition, zpl_free_cached_objects was made into a no-op as I'm not
yet sure how to properly implement that function.

Signed-off-by: Prakash Surya <surya1@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Issue #2110

Details

Provenance
Prakash Surya <surya1@llnl.gov>Authored on Jan 3 2014, 7:40 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Feb 22 2014, 12:10 AM
Parents
rG1e3cb67b53fb: Revert "Return -1 from arc_shrinker_func()"
Branches
Unknown
Tags
Unknown

Event Timeline

Brian Behlendorf <behlendorf1@llnl.gov> committed rG94520ca4626c: Prune metadata from ghost lists in arc_adjust_meta (authored by Prakash Surya <surya1@llnl.gov>).Feb 22 2014, 12:10 AM