LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Server Perfomance (https://www.linuxquestions.org/questions/linux-newbie-8/server-perfomance-610941/)

chaotix2003 01-03-2008 06:08 PM

Server Perfomance
 
Hi All
I have a dedicated virtual server and I seem to be having memory issues (or so I think)
Here is the problem, my server has slowed down within the last 1 week. The only change that I made was to enable the use of sessions (auto-start) and now it seems like everything is at a crawl. This is the information that I get when I run the top command (see below). I am not sure why i have 99.9% for id, is this normal? I have also rebooted the server a couple of times. Does the information below look normal? Thanks

Cpu(s): 0.1% us, 0.0% sy, 0.0% ni, 99.9% id, 0.0% wa, 0.0% hi, 0.0% si


top - 16:56:05 up 1 day, 32 min, 1 user, load average: 0.02, 0.01, 0.00
Tasks: 49 total, 1 running, 48 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.1% us, 0.0% sy, 0.0% ni, 99.9% id, 0.0% wa, 0.0% hi, 0.0% si
Mem: 8145044k total, 8119404k used, 25640k free, 51152k buffers
Swap: 12578884k total, 4433488k used, 8145396k free, 1047016k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1 root 16 0 2052 656 572 S 0 0.0 0:00.46 init
16254 root 16 0 1728 584 492 S 0 0.0 0:00.59 syslogd
16285 named 20 0 90788 25m 2108 S 0 0.3 0:01.37 named
16309 root 16 0 5316 980 660 S 0 0.0 0:01.14 sshd
16320 root 18 0 2716 836 676 S 0 0.0 0:00.00 xinetd
16332 root 16 0 4696 488 244 S 0 0.0 0:00.00 vsftpd
16365 root 17 0 2528 1172 1008 S 0 0.0 0:00.00 mysqld_safe
17441 mysql 15 0 396m 45m 3548 S 0 0.6 0:01.10 mysqld
17635 cyrus 16 0 10832 2720 1604 S 0 0.0 0:00.20 cyrus-master
17652 cyrus 15 0 30732 484 176 S 0 0.0 0:00.15 idled
17654 cyrus 18 0 32396 2156 1748 S 0 0.0 0:00.00 imapd
17655 cyrus 18 0 32396 2164 1756 S 0 0.0 0:00.00 imapd
17656 cyrus 18 0 32096 2128 1732 S 0 0.0 0:00.00 pop3d
17657 cyrus 18 0 32096 2128 1732 S 0 0.0 0:00.00 pop3d
17659 cyrus 18 0 32396 2152 1744 S 0 0.0 0:00.00 imapd
17660 cyrus 18 0 32096 2128 1732 S 0 0.0 0:00.00 pop3d
17666 root 16 0 30848 27m 2148 S 0 0.3 0:01.44 spamd
17723 cyrus 18 0 32396 2152 1744 S 0 0.0 0:00.00 imapd
17728 cyrus 18 0 32396 2152 1744 S 0 0.0 0:00.00 imapd
17729 cyrus 18 0 32396 2152 1744 S 0 0.0 0:00.00 imapd
17748 cyrus 20 0 32096 2128 1732 S 0 0.0 0:00.00 pop3d
17749 root 16 0 32712 28m 1848 S 0 0.4 0:01.67 spamd
17750 root 16 0 30848 25m 600 S 0 0.3 0:00.00 spamd
17781 root 16 0 6612 1704 1364 S 0 0.0 0:00.04 master
17837 postfix 15 0 6740 1784 1432 S 0 0.0 0:00.00 nqmgr
17850 root 17 0 305m 119m 14m S 0 1.5 0:34.84 java

stefan_nicolau 01-03-2008 07:15 PM

id stands for idle. Your cpu is 99.9% free. Your problem seems to be that something is using your ram (12GB of it!). Your server is already using 4GB of swap! Try posting the output of
Code:

ps -eo comm,vsz,%mem
As far as I can see, mysql is using 400mb of ram and java is using 300mb, still far from the 12GB...

syg00 01-03-2008 08:49 PM

Slight amendment - maybe make that
Code:

ps -eo comm,vsz,%mem --sort=-vsz
Still and all; no CPU, no I/O wait, truckloads of cache/buffer in use .... nothing obviously wrong.
What does sar (or even vmstat) show ???.
If it were me and I was concerned enough, I'd try forcing all the apps back into real. Force drop all the caches (recent 2.6 kernel needed), then swapoff each extent in turn. It'll fail if storage can't be acquired.

Then add the swap back, and watch sar for a few days.


All times are GMT -5. The time now is 11:38 AM.