Neil Gunton wrote:
>
> Sorry to bother you again, but I want to make sure that I am reading
> this right. This is the output from the 'free' command:
>
> [root@server /root]# free
> total used free shared buffers cached
> Mem: 516952 503816 13136 59912 87784 335176
> -/+ buffers/cache: 80856 436096
> Swap: 1028120 680 1027440
>
> Does this look ok? I am thinking that maybe the big "used" memory number
> is simply being used for cache (the large cache number hints at this).
> So, does this mean that the cache memory is not really "used" so much as
> just being utilised for optimization? Would it be made available if some
> other process (e.g. apache) needed it?
The common rule I have found with Linux systems, is that memory used
will grow to how much memory you have, but no more. So even if you have
a gig of ram, over a period of time it will all appear to be "used", but
its just keeping cached copies of things around. You'll find that if
nearly all memory appears "used" and you start up apache/other big
process, nothing goes into swap. Cached memory just gets discarded.
To see how much memory you really have free, right a dirty one line perl
script that just goes and allocates tons of memory. A forever loop that
keeps adding to an array works great... just kill it when the system
starts getting laggy. Once you've killed it, your swap should be nearly
empty and you should have a lot more "free" memory.
Your system does seem to be ok to me though.
> Again, sorry to bring this up, I realize it's not really about Embperl -
> it's just that there are a lot of knowledgeable people here, and I want
> to make sure the server problems I was experiencing are not due to me
> being brain dead (as usual)...
I think its still fairly on topic...
--
Regards,
Wim Kerkhoff, Software Engineer
Merilus, Inc. -|- http://www.merilus.com
Email: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]