5

I haven't even set up my website on my dedicated server so I'm the only one using it at the moment. And yet this is what I see in my sys info:

alt text Full Size

I just got a bunch of security softwares installed today so I'm wondering if that could be the reason. Programs like Dos deflate, CSF firewall, Mod_security, SIM, Log watch, etc.

My server's details:

 CentOS Processor Intel Xeon CPU X3220 CPU Speed 2.39 GHz Cache Size 4.00 MB RAM 2GB DDR2 

4 Answers 4

12

Your picture shows 56% cached memory. Linux works with kernel and cache loaded in the RAM to speed up things. When you have more applications taking up memory, the cache will be reduced to trade off its advantages for running more apps.

In short, things are fine; you are not running out of memory.
The Kernel+Apps memory utilization is near the 30% mark.

Update: sebthebert gave this nice link to LinuxAteMyRam for more reading on the subject.

3
  • 3
    Exactly right. UNIX, Linux and MacOS X all think that free memory is wasted memory and tries to spend it all on cache. Commented Oct 10, 2009 at 7:16
  • 2
    @Roy, even Windows does this as of Vista/2008. I have 3GB in my laptop, at the moment there's about 8MB free, and more than 1.5GB is cached. Commented Oct 10, 2009 at 8:13
  • For more information about that: linuxatemyram.com Commented Oct 10, 2009 at 21:53
3

It's using 600MB of memory at the moment - you must have quite a few things running, but it's not unreasonable.

Ignore the 'buffers' and 'cached' lines - those are disk buffers and disk cache. The system's just using that because it's there.

Look at the 'Kernel + Applications' line to see what the programs are actually using.

1

There's nothing wron with that picture. My server with 768M RAM routinely sits at or near 100% utilization - even when the load averages are 0.01 0.01 0.01 and the busiest process is top.

If, after running your server with its "real" load, it's running out of memory, that's when you start worrying :)

2
  • Load averages have nothing to do with memory usage. Commented Oct 11, 2009 at 13:12
  • that's my point, actually - memory usage is only one component, and one not really to worry about unless your CPU or disk I/O is getting hammered as well Commented Oct 11, 2009 at 14:40
0

Another tool to use is free:

<~> $ free total used free shared buffers cached Mem: 4148872 3969128 179744 0 160308 3125864 -/+ buffers/cache: 682956 3465916 Swap: 2144652 5172 2139480 

The first line mirrors what you see, that only 179M is free. The second line shows the real number, 3.465G, with all buffers and cache removed.

You must log in to answer this question.