Seeing less than half RAM for /tmp and ramdisk?


Recommended Posts

I have 128GB of RAM in my system (AMD EPYC) and Unraid clearly reads all 128GB but yet only shows half that is available in /tmp or a /ramdisk I've created.  I was aware of /dev/shm only allocating half ram but I was under the impression that /tmp would be able to see and use all available ram, and same for a user created ramdisk.  Am I missing something?

 

image.png.24e6ade8a22104d698fe7eb066b522bc.png

 

 

EDIT:  It looks like Unraid is caching more than half my RAM but not making that RAM available?

 

image.png.61877adfea18cef754d9a6f08ab539a7.png

Edited by IamSpartacus
Link to comment
7 hours ago, Squid said:

/tmp is mounted to use 50% of the memory available maximum.

 

Cached memory should be always as much as possible.  Cache is always returned to the system when a process needs it, and unused RAM is wasted RAM.  https://www.linuxatemyram.com/

 

So if I start writing more than 63GB to my ramdisk more ram ram should be allocated on the fly to accommodate?

 

I ask because I'm not seeing that happen.  I use my ramdisk for incomplete usenet downloads and when that 63GB is filled I cant write anymore.  Meanwhile I have another 40+GB of free RAM apparently doing nothing.

Link to comment
2 minutes ago, IamSpartacus said:

 

So if I start writing more than 63GB to my ramdisk more ram ram should be allocated on the fly to accommodate?

 

I ask because I'm not seeing that happen.  I use my ramdisk for incomplete usenet downloads and when that 63GB is filled I cant write anymore.  Meanwhile I have another 40+GB of free RAM apparently doing nothing.

No. Your ramdisk is not resized on the fly. Memory is used as I/O buffer and released to other processes as needed, but this has nothing to do with your ramdisk allocation.

Link to comment
36 minutes ago, Squid said:

If the memory is required, then another process can use it.

 

IE: On a 16Gig system, you will see that rootfs (where /tmp is) is sized at ~ 7.8G.  But you can run (quite easily) 3 VMs at 4Gig a piece without running out of memory.  The memory used (ie: dashboard) will reflect this.

 

I'll have to test it again as I could have sworn /tmp was acting the same as my ramdisk.  And I switched to using a ramdisk because I like having easy access to it via an SMB share for insight as I use it for a bunch of services (plex and Emby transcoding, downloads, etc.).

Edited by IamSpartacus
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.