question : slow response

Rick Stevens rstevens at vitalstream.com
Mon Jul 26 18:07:41 UTC 2004


GoijI P wrote:
>> That is not a useful indicator.  Mine says
>>
>> Filename                        Type            Size    Used    Priority
>> /dev/hda5                       partition       1028120 87336   -1
>>
>> Size is just the created size of the swap partition and is not related
>> to how heavily it is being used.  For that information, look at the
>> value under "Used".  Sometimes a more useful command is "free" which
>> reports amount of real and vitual memory being used.  And you don't
>> have to be root to run it.
>>
>> When your system starts running slowly, run the "top" command to see
>> which process(es) is consuming the most resources.  "man top" for more
>> information.  That, too, can be run by mere mortals.
>>
>> > Does not seem to be worms related.RH9.
>>
> 
> ran free:
> out of 1GB RAM on server only 23MB was free.
> after reboot almost all became free.
> memory leak?.  i never reboot my server.
> top does not show any abnormality.

Memory is often allocated at the beginning.  Memory won't be "free"
unless memory which was committed to a program is actually needed
(this prevents the machine from swapping too often).

If you think you're swapping, look a the "used" and "free" bits for
the "swap" (fourth line) of the "free" output.  You can also "vmstat 5"
to watch the system activity.  Look at the "si" (swap in) and "so" (swap
out) columns to see if the system is really swapping.  If you see that
those numbers are greater than zero more often than not, then the system
is swapping and you have a bit more investigation to do.  Hit CTRL-C to
terminate the vmstat program.

Make sure you look at the "top" report WHEN YOUR SYSTEM IS SLOW to see
what's going on.  Don't just look at the "% CPU" column, also look at
the "SIZE" and "RSS" columns.

The biggest "SIZE" is the process that's using the most memory, the
biggest "RSS" is the process that has the largest program code size.  If
you see a process where the "SIZE" is growing but the "RSS" is more or
less the same, that's a potential memory leak.  Unless you've written
your own code and haven't taken care to free allocated memory or haven't
kept your machine current, the odds of a memory leak are pretty small.
----------------------------------------------------------------------
- Rick Stevens, Senior Systems Engineer     rstevens at vitalstream.com -
- VitalStream, Inc.                       http://www.vitalstream.com -
-                                                                    -
-    First Law of Work:                                              -
-    If you can't get it done in the first 24 hours, work nights.    -
----------------------------------------------------------------------





More information about the Redhat-install-list mailing list