Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

MR_Boogy

macrumors regular
Original poster
Apr 6, 2012
144
19
I've already upgraded my 3.1GHz iMac to 32GB which is needed as I run VMs, it reports I'm using maybe 12GB minimum but I'm not maxing it out.
I noticed it says 20GB is being used for file optimisation or something, what's that?
I'm wondering if going up to 64 would show any improvement, given my VM images are ~30GB... might MacOS load the entire VM in RAM or would it be be wasted?
 
macOS works under the premise that unused RAM is wasted. To a great extend it will use the RAM it has available for something. That includes what it calls file caching, where it tries to predict what file blocks you might access later or has recently accessed but aren’t actively using anymore and keeps it in RAM/doesn’t evict it. This reduces disk reads and is of course faster than a disk read. A lot of people interpret this incorrectly however. I see a lot of cases where people with very low memory pressure in the green see a lot of their RAM as “used” and think they *need* more RAM when in reality it’s just the caching using it, and not active app or wired memory.

As of whether it might speed anything up for you, it’s hard to say definitively. I would think probably not noticeably if your memory pressure is in the green. While it might cache more things I hardly think you’d really notice it honestly.
If however you would like the whole VM to be in RAM instead of whatever macOS may decide to cache, you can set up a tmpfs ram disk and manually copy your VM to that. Just remember to flush it to disk after you’re done since RAM is volatile. And preferably be connected to a UPS so you don’t lose data before you flush it. The advantage there would then be though that you’d also never have to flush to disk before you’re ready. That’s a data risk if somehow power is lost or a crash occurs before you flush, but it’s a major speed boost over having to flush dirty pages to disk on every write, even if we assume a coalescing write model
 
  • Like
Reactions: Ledgem and MR_Boogy
This is a question that if you have to ask, then... you don't really NEED it.

(those who DO need 64gb know WHY they need it, and therefore don't have to "ask"...) :cool:
 
This is a question that if you have to ask, then... you don't really NEED it.

(those who DO need 64gb know WHY they need it, and therefore don't have to "ask"...) :cool:
I didn't ask if I need it, or NEED it, I asked if I'd see a benefit from it.

I'm partly thinking along the lines that the iMac is very pernickety what RAM it lets you use, if in future years I might find I can't get another pair of the same 16Gb DIMMs I installed. So if I go from running one VM to running 4, I might be kicking myself I didn't spend a bit more now.
Although is RAM more pricey than it was before the chip-shortage?
 
I did like that the iMac will support up to 128, if I ever need it.
 
I did like that the iMac will support up to 128, if I ever need it.
Only the Intel models. For the M1 you're stuck with a max of 16.

On an upgradable Mac, soon to be an endangered species, I always pack it with the max if I can afford it (third-party RAM, I'm not foolish enough to pay Apple prices for RAM). With the bloat Apple keeps adding to the OS I figure I may well need it before Apple finally makes it artificially obsolete by no longer supporting that iteration of the Mac.
 
I did explicitly say it was a Retina iMac, though the M1X or M2 is coming very soon. I have to disagree though. I ran my old MM2012 through 3 (4?) major MacOS versions including the x64 switch and after 10 years it was still easily fast enough for my use. Only got rid of it because the hardware was dying on me. I'd have gone with the Intel MM 2018 but user RAM replacement was much more complicated and as you say, I wasn't going to pay Apple RAM prices :)
 
I also use a Parallels Desktop virtual machine running Windows 10 using 64GB of RAM, which easily fills up enough for now!
 

Attachments

  • QQ20210907-043910@2x.jpg
    QQ20210907-043910@2x.jpg
    63.8 KB · Views: 56
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.