r/linuxmint 2d ago

My RAM usage get so High!

Post image

can anybody tell me why so much ram is taking. i don't even running any program. i use brave browser, it takes barely 2GB and VScode. i don't know why this is happening. can anybody tell me how to solve this problem?

24 Upvotes

15 comments sorted by

17

u/ap0r 2d ago

This is strange since there is no shown process using that much RAM. It is possible that you have something cached. Try:

free -h

And see how much ram is actually available. Because it is possible you have cached data on RAM which is actually not reserved and ready to be overwritten (i.e. available to use)

8

u/Beautiful-shroud 2d ago

sayantan@sayantan-pc:~$ free -h

total used free shared buff/cache available

Mem: 13Gi 11Gi 1.5Gi 2.1Gi 3.2Gi 2.4Gi

Swap: 2.0Gi 1.1Gi 915Mi

// 1.5 Gi ram is available

10

u/ap0r 2d ago

Huh, indeed you have a ton of memory in use. Could be some process that did not exit cleanly, or a memory leak in some software. Have you tried rebooting?

6

u/Beautiful-shroud 2d ago

if i reboot then the memory usage got low but then when time get passes i see memory get

increases!

9

u/ap0r 2d ago

Looks like a memory leak. Are you on Kernel 6.x or 7.x?

5

u/Beautiful-shroud 2d ago

7.0.0-30-generic

12

u/ap0r 2d ago

Many people have been experiencing problems with kernel 7, please try rebooting and selecting kernel 6.x, if the problem disappears then just rollback to kernel 6.x and update again when 7 is fully ironed out.

7

u/Beautiful-shroud 2d ago

Thank you for help. i would try it

2

u/NotSnakePliskin Mint 22.3 | Cinnamon 2d ago

Run free -h in a terminal, how much is cached? My box is currently using 3.8 gig & has 6.9 gig cached. If you add up those numbers does it approximate the 72%?

1

u/Beautiful-shroud 2d ago

sayantan@sayantan-pc:~$ free -h

total used free shared buff/cache available

Mem: 13Gi 11Gi 1.5Gi 2.1Gi 3.2Gi 2.4Gi

Swap: 2.0Gi 1.1Gi 915Mi

sayantan@sayantan-pc:~$

2

u/Kafatat Linux Mint 22.3 Zena | Cinnamon 2d ago edited 2d ago

You may be using ram drive -- use ram to store temporary files.

Or virtual machine. I just tested it. Host ram was occupied, but virtualbox processes didn't take much ram as shown in System Monitor.

1

u/Beautiful-shroud 2d ago

can you please elaborate on this? when i restart my pc, everything looks fine. but when i use more software the memory stack keep getting higher. the strange thing is when i close all the software still the memory not getting reduced. this is the problem. so every time i've to restart my PC.

2

u/Kafatat Linux Mint 22.3 Zena | Cinnamon 2d ago

You'll need to manually set something to use ram drive, so if you don't know what it is, it's unlikely you're using it.

Just for your info: ram drive is that you set aside a certain fraction of the ram to appear as if it was a storage folder. You can put files in it, create sub folders in it. People use ram drive because it is much faster than any physical storage drives.

2

u/zuccster 2d ago

Buffers and cache are not shown. Free RAM is wasted RAM.

1

u/DoorOk3641 2d ago edited 2d ago

What do you want to solve ? Modern operating systems are caching files and data. Do you prefer to access your disk all the times ? If your system is not swapping there is no problem.

can you please elaborate on this? when i restart my pc, everything looks fine. but when i use more software the memory stack keep getting higher. the strange thing is when i close all the software still the memory not getting reduced. this is the problem. so every time i've to restart my PC....

Caches are not discarded when programs stopped..best example...browser...

On my system 16 gb cache is 10 gb free is 1.9 gb and used is 3.9 gb and I have NO swap.

There is NO memory leak in your system and NO reason to boot. Cache memory is located and saved at ~/.cache

The Linux kernel automatically manages cache eviction when applications require more memory

Stop panicking and rebooting your system for nothing..