5

I have a debian system. It has 8GB memory. When I do top it shows 7.9 GB memory used and rest free. I add up the memory usage of all the programs running from top and they hardly sum up to around 50 MB. So, where is rest of the memory being used? Can I have a better detailed info of the memory usage? What is a better way to check the memory usage?

Incredible
  • 141
  • 1
  • 1
  • 4

4 Answers4

15

See: Help! Linux ate my RAM!

Nick Kavadias
  • 10,758
  • 7
  • 36
  • 47
2

Answered in other questions, but the short answer is that what you want for used memory is the following number from the output of the command free:

-/+ buffers/cache: 557896

Kyle Brandt
  • 82,107
  • 71
  • 302
  • 444
1

I commonly run into this problem on various UXIX flavors. Unless otherwise configured, they buffer everything they read. Free memory goes to near zero eventually, and will stay there forever. Unless the memory is used for something else, all the startup scripts remain buffered forever.

Administrators who don't understand that most buffers are relatively memory may refuse to increase the size of memory structures. This can (severely) degrade performance of some applications.

BillThor
  • 27,354
  • 3
  • 35
  • 69
0
cat /proc/meminfo

will give you the kernel's idea of how your memory is being used. The appropriate man page about it will help you understand what you're looking at.

pjz
  • 10,497
  • 1
  • 31
  • 40