3

I don't quite understand the output from the free -h command. I have tried searching but am still not quite sure.

Should I be worried my free memory is only 46M or is the -/+ buffers/cache row value that says 351M free also available for whatever?

             total       used       free     shared    buffers     cached         
Mem:          594M       548M        46M        76M        28M  277M
-/+ buffers/cache:       242M       351M
Swap:           0B         0B         0B

If it matters, this is a web server that hosts a few websites that don't get more than 30 visits per day each.

Rui F Ribeiro
  • 56,709
  • 26
  • 150
  • 232

1 Answers1

2

The -/+ buffers/cache indicate the size of RAM that is dedicated directly for read/write by all the process of running applications.

When you run free with -m flag, -/+ buffers/cache is the most important row to look at. In your case, it doesn't mean that (351+46)Mb is your total free memory but is a way to visualize that 242 Mb has been used by processes and 351Mb of buffers/cache in RAM is dedicatedly free for other application to use.

Linux always tries to use RAM to speed up disk operations by using available memory for buffers (file system metadata) and cache (pages with actual contents of files or block devices). It may be noted that if a system has been running for a while, a small number can be seen under the free column of the mem row.

Ashish K
  • 332