RAM Recommendation Clarification?

Status
Not open for further replies.

mattlach

Patron
Joined
Oct 14, 2012
Messages
280
Hey all,

The hardware guide recommends 1GB RAM per TB of storage.

Is this per TB of AVAILABLE storage, or per TB of TOTAL Storage?

I plan on using RAIDz2 with 4 3TB drives. This will be a total of 12TB of drives, but only 6TB available. Shoudl I use 12 or 6TB of RAM for this configuration?
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
Not sure how accurate that 1GB per 1TB of storage really is but it's against the total available as I understand it. You must be running in a VM? I would choose 8GB if you have it available but I'm sure you could get away with 4GB as I was running 4GB on four 2TB drives configured as RaidZ1 (~6TB available). Also keep in mind that if you create swap space (2GB default per drive) then you have that to fall back on but there is a performance hit.
 

mattlach

Patron
Joined
Oct 14, 2012
Messages
280
Not sure how accurate that 1GB per 1TB of storage really is but it's against the total available as I understand it. You must be running in a VM? I would choose 8GB if you have it available but I'm sure you could get away with 4GB as I was running 4GB on four 2TB drives configured as RaidZ1 (~6TB available). Also keep in mind that if you create swap space (2GB default per drive) then you have that to fall back on but there is a performance hit.

Yes, it will be running in a VM. :)

RAM is not scarce (the ESXi server has 32GB), but I also don't want to over-provision and waste it, if I can use it elsewhere.

I understand FreeNAS uses RAM rather effectively for caching.

If I have spare RAM, would it be a good idea to just give it as much RAM as I can for caching purposes?
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
As I understand it, the more RAM you can toss at it will only make it better. I don't use ESXi but I know my VMWare Workstation will only give up as much RAM as the client desires. In other words, if I allocate 8GB RAM to a VM but the VM only wants 1GB, then VMWare only gives up 1GB and leaves the rest for other use. Of course if the VM does want more RAM, it will provide it as needed up to the amount you specify. Again, I'm not a VMWare expert at all, just dabble a bit. I think you should try 8GB and see what the performance is like and then up it if you like. My only recommendation is to not go below 4GB.
 

mattlach

Patron
Joined
Oct 14, 2012
Messages
280
As I understand it, the more RAM you can toss at it will only make it better. I don't use ESXi but I know my VMWare Workstation will only give up as much RAM as the client desires. In other words, if I allocate 8GB RAM to a VM but the VM only wants 1GB, then VMWare only gives up 1GB and leaves the rest for other use. Of course if the VM does want more RAM, it will provide it as needed up to the amount you specify. Again, I'm not a VMWare expert at all, just dabble a bit. I think you should try 8GB and see what the performance is like and then up it if you like. My only recommendation is to not go below 4GB.

Thank you.

I'll give it a shot and see how it works.

I'm still ordering some of my drives, so when I get them in, I'll do my install.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
As I understand it, the more RAM you can toss at it will only make it better. I don't use ESXi but I know my VMWare Workstation will only give up as much RAM as the client desires. In other words, if I allocate 8GB RAM to a VM but the VM only wants 1GB, then VMWare only gives up 1GB and leaves the rest for other use. Of course if the VM does want more RAM, it will provide it as needed up to the amount you specify.

The problem with this is that "client desires" is effectively "operating system attempts to allocate". In the case of ZFS and FreeNAS, it will rapidly attempt to use all memory in an attempt to cache effectively. What you don't really want is to allocate MORE memory to FreeNAS than you can afford to spare; VMware will helpfully page "lightly used" memory pages out to disk when ESXi memory gets tight, and then suddenly your FreeNAS system will be randomly needing to page in stuff off disk, and you will see all sorts of crummy behaviour, poor performance, and other oddities. You're probably better off allocating 8GB or 12GB to FreeNAS, and telling ESXi to reserve that memory, even if maybe you aren't allocating quite as much memory as you could afford to.
 
Status
Not open for further replies.
Top