2

All my websites on my server are extremely slow or not loading at all. Even server admin (Plesk) will not load some times.

There's been no changes to the sites for the last coupple of months.

How can I see what processes is making my server slow?

My environment looks like this:

Server: VPS running Linux 2.8.x
OS: Centos 5
Manage interface: Plesk 9.x
Memmory: 1024MB
CPU: 2.2GHz

My websites run on PHP and MySQL.

I finally managed to telnet (Putty + SSH) in to my server. Running top did not show any processes using more than max 2% CPU and none were using exesive memmory.

I also got a friend to install a program that checks the core files, and all seemed fine.

So I'm leaning towards network issues or some other server malfunction. But I'm not able to find out what can be wrong.

Here are some answers to Sean Kimball:

  • I don't run mail services on my server yet
  • There are noe specific bandwidth peaks.

Prefork looks like this

<IfModule prefork.c>
StartServers       8
MinSpareServers    5
MaxSpareServers   20
ServerLimit      256
MaxClients       256
MaxRequestsPerChild  4000
</IfModule>
  • Not sure what you mean with DNS question. But I think it's up and running.
  • There are no processes running wild
  • Where can I find avarage load?

    Telnet is disabled and I have to log in using SSH :)

Steven
  • 275

5 Answers5

2

Can you tell us a little more about your environment - ram, cpu, is this a virtual machine, plesk version.. etc. Also, is it just Apache that is slow, mail, ftp, dns etc all are fine?

  • Check your mail queue [qmqtool is excellent for this]
  • Check your bandwidth & throughput, was/is there a spike
  • If this is a virtual machine, you should be able to troubleshoot using the virtuozzo tools
  • Have you 'tweaked' your apache config? specifically this part:

    <IfModule prefork.c>

    StartServers 2
    MinSpareServers 2
    MaxSpareServers 5
    ServerLimit 200
    MaxClients 200
    MaxRequestsPerChild  4000
    

    </IfModule>

  • DNS, is it running? do your forwarders answer queries.

  • ps -ax, any odd processes you can't identify?
  • what does your average load look like at any given time?

Finally, unrelated to your issue, get SSH working & shut telnet down - for godssakes please!

2

You can see your load average running uptime.

Since your server is a VPS, the CPU power might not be fully yours and other users’ actions (that use the same hardware as your VPS) may have influence on your server. I experienced that on my own.

Another check worth might be iotop.

exic
  • 638
1

if you can't remote into it, can you get in via console? top would help, will give sorted processes by cpu, pressing M when inside top would sort by highest memory usage.

Output looks like enter image description here

R D
  • 203
0

I don't know if Plesk has a utility for monitoring. You can install a monitoring software with web interface.

http://en.wikipedia.org/wiki/Comparison_of_network_monitoring_systems

0

Does Plesk give you any kind of performance/status information?

If you can upload files to your web server still, you can try uploading a file that will execute shell commands and display the output.

For example, you can try this:

<?php

exec('TERM=xterm /usr/bin/top n 1 b i', $top, $error );
echo nl2br(implode("\n",$top));
if ($error){
    exec('TERM=xterm /usr/bin/top n 1 b 2>&1', $error );
    echo "Error: ";
    exit($error[0]);
}

?>

Since this is run in as you webserver's user, you won't see a full process list, but you can see some system information (CPU, Mem, and Swap usage, load, etc...). That might give you some more information into the problem.

pferate
  • 473