High Wired memory usage !!

shahzaib

Active Member

Reaction score: 1
Messages: 110

Hi,

We've 96 GB memory and I can see that 76 GB is wired and there's also total ARC 69 GB already occupied. My question is, if FreeBSD requires additional memory for processes will wired/ARC release the memory for FreeBSD usage to prevent swap usage? Since 12 GB is only free. Will OS start going into swap if 12 GB free gets utilized instead of using memory from wired or ARC?

http://prntscr.com/d2jwad
 

Remington

Aspiring Daemon

Reaction score: 169
Messages: 534

Try adding this to /boot/loader.conf and see if it helps. My server got 96GB memory and set the arc to 4G with no issues.

Code:
vfs.zfs.arc_max="4G"
 
OP
OP
S

shahzaib

Active Member

Reaction score: 1
Messages: 110

But it'll minimize ARC caching which we need to serve content from caching. Current default is :
Code:
vfs.zfs.arc_max: 99317161984
vfs.zfs.arc_min: 12414645248
Regarding vfs.zfs.arc_min, does that mean if OS requires memory ARC will release it up to the point on its vfs.zfs.arc_min commitment? Which is by default 12 GB on this system.

My main concern is, will OS release ARC memory if requires to?
 

Remington

Aspiring Daemon

Reaction score: 169
Messages: 534

It'll change depending on how much buffer it needs to write to zfs pools so you may want to limit the buffer to 4 or 8G. If you are using deduplication or compression with heavy writes then arc_max needs to be raised to improve the write time.
 

kpa

Beastie's Twin

Reaction score: 1,810
Messages: 6,318

Remington, the ARC cache is purely a read cache.

Depending on how this server is used the 4GBs of ARC cache just may not cut it. If this is a heavy duty file server that is mostly read-heavy and less writes to the ZFS pool you definitely want to give it as much ARC cache as you can without compromising the other functionality of the operating system. From the looks of it you could limit the maximum size of the ARC cache to 64GBs if my assumption about the use of this server is correct?

The size of the cache will autoscale if free memory becomes scarce but it may be a better idea to use manually set maximum limit to be on the safe side.
 

Remington

Aspiring Daemon

Reaction score: 169
Messages: 534

Remington, the ARC cache is purely a read cache.

Depending on how this server is used the 4GBs of ARC cache just may not cut it. If this is a heavy duty file server that is mostly read-heavy and less writes to the ZFS pool you definitely want to give it as much ARC cache as you can without compromising the other functionality of the operating system. From the looks of it you could limit the maximum size of the ARC cache to 64GBs if my assumption about the use of this server is correct?
Thanks for clarifying that. My server have SSD so arc with 4GB is not an issue. I would say 4GB is bare minimum for a web server as I haven't run into any issues for 2 years.
 
Top