Limiting ZFS ARC Size?

Shane Ambler FreeBSD at ShaneWare.Biz
Mon Jun 25 03:06:12 UTC 2018

On 24/06/2018 21:48, Bob Willcox wrote:
> On Sun, Jun 24, 2018 at 09:32:41AM +0100, james wrote:
>> On 18/06/2018 17:24, Bob Willcox wrote:
>>> to the point where my running processes (such as firefox) start page
>>> thrashing.
>> I thought ARC was supposed to give up memory if there is memory pressure 
>> that causes applications to page?
> That was what I was expecting as well. However ARC had consumed most of the
> memory (about 25G, 30G was wired) and firefox was paging like crazy. I did
> discover what program was causing ARC to grow seeming unbounded, it was vlc.
> I have something over 64k audio tracks that I had pointed vlc to with shuffle
> set. It must be recursively reading all of the files in the heirarchy and zfs
> is cacheing a bunch of data as it goes.

Create a zfs for your a/v files, then set its caching to metadata only.

ARC use -
- primarycache=all | none | metadata
L2ARC use -
- secondarycache=all | none | metadata

Also have a look at
I am finding ARC releasing much quicker/easier with this patch.

FreeBSD - the place to B...Software Developing

Shane Ambler

More information about the freebsd-questions mailing list