Ubuntu – Can I use all the RAM for application data

cachememory usageramsystem-monitor

I have yet another question about "where is my Linux memory"

Question goes: can I use cache for application data?

On my laptop I have 1GB ram. Situation after some time of work: browser takes 400MB and all other apps caa 300MB (quickly summed in system monitor). System monitor says I use 90% of RAM and I have already 200MB on swap. Laptop is getting slower when I start new things (e.g. open new tab in browser or open new Nautilus window). probably putting memory on swap

So there should be 1200MB (ram+swap) used but all app I see uses only 600MB. Where are other 600MB? Out of this 600MB there is 400MB real RAM.

I am not copying or any other massive IO activity.

I read about Linux smartly uses all ram it has using buffers and cache. So, kernel (cache) uses 300MB. What if I don't want to have disk mirrored and I want to use memory for application data (e.g. new browser tab)? I don't need 200MB of mirrored disk data, because I (for example) won't use open the same photos on data partition I just seen.

So can I use all my RAM for application data? (including browser, desktop, xorg, other services). How?

Best Answer

Applications use ram on their own; you don't have to DO anything. Whatever ram ISN'T in use by applications is used to cache recently accessed files to speed things up if they are needed again, thus between the two, ram usage is usually close to 100%. As applications request more ram, the cache gives it up.

Related Question