What is consuming memory?

Posted by Milan Babuškov on Server Fault See other posts from Server Fault or by Milan Babuškov
Published on 2010-06-05T23:06:47Z Indexed on 2010/06/05 23:12 UTC
Read the original article Hit count: 450

Filed under:
|
|
|

Feel free to change the question title.

I have a VPS with standard LAMP stack and a busy website. Operating system is CentOS 5.5. Virtualization is done with VMWare. My server gets real slow about every 6 hours. Logging into it I see that 1.6GB of RAM is consumed. However, listing the active processes does not explain the problem. Can anyone make any sense of this?

"free" shows this:

             total       used       free     shared    buffers     cached
Mem:       2059456    2049280      10176          0      14780     380968
-/+ buffers/cache:    1653532     405924
Swap:      2096472         96    2096376

While this is output of "ps":

[root@vmi29 /]# ps aux
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
root         1  0.0  0.0  10348   688 ?        Rs   Jun05   0:01 init [3]
root         2  0.0  0.0      0     0 ?        S<   Jun05   0:00 [migration/0]
root         3  0.0  0.0      0     0 ?        SN   Jun05   0:00 [ksoftirqd/0]
root         4  0.0  0.0      0     0 ?        S<   Jun05   0:00 [migration/1]
root         5  0.0  0.0      0     0 ?        SN   Jun05   0:00 [ksoftirqd/1]
root         6  0.0  0.0      0     0 ?        S<   Jun05   0:00 [migration/2]
root         7  0.0  0.0      0     0 ?        SN   Jun05   0:00 [ksoftirqd/2]
root         8  0.0  0.0      0     0 ?        S<   Jun05   0:00 [migration/3]
root         9  0.0  0.0      0     0 ?        SN   Jun05   0:00 [ksoftirqd/3]
root        10  0.0  0.0      0     0 ?        S<   Jun05   0:06 [events/0]
root        11  0.0  0.0      0     0 ?        S<   Jun05   0:00 [events/1]
root        12  0.0  0.0      0     0 ?        S<   Jun05   0:00 [events/2]
root        13  0.0  0.0      0     0 ?        S<   Jun05   0:00 [events/3]
root        14  0.0  0.0      0     0 ?        S<   Jun05   0:00 [khelper]
root        31  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kthread]
root        38  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kblockd/0]
root        39  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kblockd/1]
root        40  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kblockd/2]
root        41  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kblockd/3]
root        42  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kacpid]
root       204  0.0  0.0      0     0 ?        S<   Jun05   0:00 [cqueue/0]
root       205  0.0  0.0      0     0 ?        S<   Jun05   0:00 [cqueue/1]
root       206  0.0  0.0      0     0 ?        S<   Jun05   0:00 [cqueue/2]
root       207  0.0  0.0      0     0 ?        S<   Jun05   0:00 [cqueue/3]
root       210  0.0  0.0      0     0 ?        S<   Jun05   0:00 [khubd]
root       212  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kseriod]
root       302  0.0  0.0      0     0 ?        S    Jun05   0:00 [khungtaskd]
root       303  0.0  0.0      0     0 ?        S    Jun05   0:00 [pdflush]
root       304  0.0  0.0      0     0 ?        S    Jun05   0:01 [pdflush]
root       305  0.0  0.0      0     0 ?        S<   Jun05   0:05 [kswapd0]
root       306  0.0  0.0      0     0 ?        S<   Jun05   0:00 [aio/0]
root       307  0.0  0.0      0     0 ?        S<   Jun05   0:00 [aio/1]
root       308  0.0  0.0      0     0 ?        S<   Jun05   0:00 [aio/2]
root       309  0.0  0.0      0     0 ?        S<   Jun05   0:00 [aio/3]
root       515  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kpsmoused]
root       582  0.0  0.0      0     0 ?        S<   Jun05   0:00 [mpt_poll_0]
root       583  0.0  0.0      0     0 ?        S<   Jun05   0:00 [mpt/0]
root       584  0.0  0.0      0     0 ?        S<   Jun05   0:00 [scsi_eh_0]
root       590  0.0  0.0      0     0 ?        S<   Jun05   0:00 [ata/0]
root       591  0.0  0.0      0     0 ?        S<   Jun05   0:00 [ata/1]
root       592  0.0  0.0      0     0 ?        S<   Jun05   0:00 [ata/2]
root       593  0.0  0.0      0     0 ?        S<   Jun05   0:00 [ata/3]
root       594  0.0  0.0      0     0 ?        S<   Jun05   0:00 [ata_aux]
root       610  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kstriped]
root       631  0.0  0.0      0     0 ?        S<   Jun05   0:05 [kjournald]
root       656  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kauditd]
root       689  0.0  0.0  13364   928 ?        S<s  Jun05   0:00 /sbin/udevd -d
root      2123  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kmpathd/0]
root      2124  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kmpathd/1]
root      2126  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kmpathd/2]
root      2127  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kmpathd/3]
root      2128  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kmpath_handlerd]
root      2203  0.0  0.0      0     0 ?        S<   Jun05   0:00 [kjournald]
root      2613  0.0  0.0   5908   648 ?        Ss   Jun05   0:00 syslogd -m 0
root      2617  0.0  0.0   3804   424 ?        Ss   Jun05   0:00 klogd -x
root      2707  0.0  0.0  10760   372 ?        Ss   Jun05   0:02 irqbalance
apache    2910  0.5  0.6 213964 12912 ?        S    00:22   0:07 /usr/sbin/httpd
dbus      3011  0.0  0.0  21256   904 ?        Ss   Jun05   0:00 dbus-daemon --system
root      3025  0.0  0.0   3800   576 ?        Ss   Jun05   0:00 /usr/sbin/acpid
68        3038  0.0  0.2  31152  4336 ?        Ss   Jun05   0:01 hald
root      3039  0.0  0.0  21692  1176 ?        S    Jun05   0:00 hald-runner
68        3046  0.0  0.0  12324   856 ?        S    Jun05   0:00 hald-addon-acpi: listening on acpid socket /var/run/acpid.s
68        3052  0.0  0.0  12324   856 ?        S    Jun05   0:00 hald-addon-keyboard: listening on /dev/input/event0
root      3105  0.0  0.0  62624  1212 ?        Ss   Jun05   0:00 /usr/sbin/sshd
root      3264  0.0  0.0  74820  1156 ?        Ss   Jun05   0:00 crond
root      3292  0.0  0.0  18416   472 ?        S    Jun05   0:00 /usr/sbin/smartd -q never
root      3300  0.0  0.0   3792   480 tty2     Ss+  Jun05   0:00 /sbin/mingetty tty2
root      3301  0.0  0.0   3792   480 tty3     Ss+  Jun05   0:00 /sbin/mingetty tty3
root      3302  0.0  0.0   3792   484 tty4     Ss+  Jun05   0:00 /sbin/mingetty tty4
root      3304  0.0  0.0   3792   480 tty5     Ss+  Jun05   0:00 /sbin/mingetty tty5
root      3306  0.0  0.0   3792   480 tty6     Ss+  Jun05   0:00 /sbin/mingetty tty6
apache    5158  0.4  0.5 211896 11848 ?        S    00:28   0:04 /usr/sbin/httpd
apache    5519  0.4  0.5 211896 11992 ?        S    00:29   0:03 /usr/sbin/httpd
root      5649  0.0  0.0  63848  1184 pts/0    S    Jun05   0:00 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --soc
mysql     5696  2.1  1.9 411060 40392 pts/0    Rl   Jun05   2:01 /usr/libexec/mysqld --basedir=/usr --datadir=/var/lib/mysql
apache    5943  0.4  0.5 211896 12000 ?        S    00:30   0:03 /usr/sbin/httpd
apache    5976  0.6  0.5 211896 11792 ?        S    00:30   0:04 /usr/sbin/httpd
apache    6073  0.4  0.5 211896 11208 ?        S    00:31   0:03 /usr/sbin/httpd
apache    6122  0.4  0.5 211896 11848 ?        S    00:31   0:03 /usr/sbin/httpd
apache    6128  0.3  0.5 211896 11940 ?        S    00:31   0:02 /usr/sbin/httpd
apache    6159  0.5  0.5 211896 11872 ?        S    00:31   0:04 /usr/sbin/httpd
apache    6636  0.4  0.6 213960 13444 ?        S    00:32   0:02 /usr/sbin/httpd
apache    6787  0.3  0.5 211884 11308 ?        S    00:33   0:02 /usr/sbin/httpd
apache    6796  0.4  0.5 211884 12024 ?        S    00:33   0:02 /usr/sbin/httpd
apache    6801  0.3  0.5 211896 11920 ?        S    00:33   0:01 /usr/sbin/httpd
apache    6804  0.4  0.5 211884 11848 ?        S    00:33   0:02 /usr/sbin/httpd
apache    6825  0.4  0.5 211896 11972 ?        S    00:33   0:02 /usr/sbin/httpd
apache    6866  0.3  0.5 210860 11044 ?        S    00:33   0:01 /usr/sbin/httpd
apache    6870  0.2  0.5 211896 11108 ?        S    00:33   0:01 /usr/sbin/httpd
apache    6872  0.3  0.5 211896 11900 ?        S    00:33   0:01 /usr/sbin/httpd
apache    6993  0.3  0.5 211896 11836 ?        S    00:33   0:02 /usr/sbin/httpd
apache    6994  0.3  0.5 211896 11792 ?        S    00:33   0:01 /usr/sbin/httpd
apache    7136  0.2  0.5 211896 11432 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7143  0.2  0.5 210860 11052 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7145  0.2  0.5 211896 11136 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7266  0.2  0.6 213952 12748 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7299  0.2  0.5 211884 11276 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7311  0.2  0.5 211884 11300 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7313  0.3  0.5 211884 11876 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7345  0.2  0.5 210872 11100 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7349  0.2  0.5 210860 11008 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7350  0.2  0.5 211896 11832 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7351  0.1  0.5 211884 11072 ?        S    00:34   0:00 /usr/sbin/httpd
apache    7352  0.2  0.5 210872 11096 ?        S    00:34   0:01 /usr/sbin/httpd
apache    7449  0.1  0.5 210860 11020 ?        S    00:35   0:00 /usr/sbin/httpd
root      7490  0.3  0.0      0     0 ?        S    Jun05   3:11 [vmmemctl]
root      7597  0.0  0.0  72656  1260 ?        Ss   Jun05   0:06 /usr/lib/vmware-tools/sbin64/vmware-guestd --background /va
apache    7720  0.1  0.5 210860 10748 ?        S    00:36   0:00 /usr/sbin/httpd
apache    7726  0.1  0.4 209836  9304 ?        R    00:36   0:00 /usr/sbin/httpd
apache    7727  0.1  0.5 210860 10916 ?        S    00:36   0:00 /usr/sbin/httpd
apache    7731  0.1  0.5 210860 10780 ?        S    00:36   0:00 /usr/sbin/httpd
apache    7732  0.3  0.5 210860 10916 ?        S    00:36   0:01 /usr/sbin/httpd
apache    7733  0.1  0.5 210872 11000 ?        S    00:36   0:00 /usr/sbin/httpd
apache    7735  0.1  0.5 211884 11048 ?        S    00:36   0:00 /usr/sbin/httpd
apache    7761  0.1  0.5 210860 10552 ?        S    00:36   0:00 /usr/sbin/httpd
apache    7776  0.1  0.4 209836  8648 ?        R    00:37   0:00 /usr/sbin/httpd
apache    7790  0.2  0.3 208812  7724 ?        R    00:40   0:00 /usr/sbin/httpd
apache    7800  0.2  0.3 208812  8088 ?        R    00:40   0:00 /usr/sbin/httpd
root      7801  0.0  0.0   3792   484 tty1     Ss+  00:41   0:00 /sbin/mingetty tty1
apache    7820  0.2  0.3 208812  7552 ?        R    00:41   0:00 /usr/sbin/httpd
apache    7834  0.2  0.3 207788  6756 ?        R    00:42   0:00 /usr/sbin/httpd
apache    7864  0.2  0.2 207788  6148 ?        R    00:42   0:00 /usr/sbin/httpd
apache    7872  0.3  0.2 207788  5856 ?        R    00:43   0:00 /usr/sbin/httpd
apache    7874  2.5  0.3 207788  6336 ?        R    00:43   0:00 /usr/sbin/httpd
root      7875  0.3  0.0  63844  1056 ?        S    00:43   0:00 sh -c lsb_release -sd 2>/dev/null
root      7879  1.6  0.0  65604   964 pts/0    R+   00:43   0:00 ps aux
root     16316  0.0  0.1  90128  3272 ?        Ss   Jun05   0:00 sshd: milanb [priv]
milanb   16358  0.0  0.0  90128  1752 ?        S    Jun05   0:00 sshd: milanb@pts/0
milanb   16360  0.0  0.0  66076  1480 pts/0    Ss   Jun05   0:00 -bash
root     16875  0.0  0.0 101068  1324 pts/0    S    Jun05   0:00 su -
root     16877  0.0  0.0  66184  1692 pts/0    S    Jun05   0:00 -bash
root     24373  0.0  0.3 206764  7348 ?        Rs   Jun05   0:01 /usr/sbin/httpd

© Server Fault or respective owner

Related posts about linux

Related posts about apache