Dynadot โ€” .com Registration $8.99

High server load, any suggestions?

Spacemail by SpaceshipSpacemail by Spaceship
Watch
Impact
109
Hey all,

Im getting very high server loads 24/7 on my VPS server. Around 50% CPU and 100% RAM usage

Specs are around minimum 400mghz cpu, 384mb ram, 20gb hdd.

Apache seems to be taking up tonnes of memory, the processes only seem to close after a minute or so per process...

I have no idea how apache works, so I do not know if anything can really be done to minimize its resource use. Here's a few screenshots of my resource using processes:
http://img236.imageshack.us/img236/1753/18ip1.png
http://img162.imageshack.us/img162/899/25ec.png
http://img55.imageshack.us/img55/1497/39om.png

Thanks in advance everyone!
Regards, Rhett.
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
AfternicAfternic
Are you using WHM on your vps? If you have, try running apache status through it and see which sites are potentially consuming your cpu and memory.

Other problems that might be strainous to your vps could be things installed like spam Assassin and mailman, where both of them are huge resource hogs.
 
0
•••
Mostlikely you need to edit your apache httpd.conf file..
 
0
•••
Do you have a server admin you can contact? Surely you must if you have a dedicated server and not familiar with Apache.
 
0
•••
If one of your sites has a lot of visitors, that may be the problem. You may need to optimize your scripts or upgrade your vps if optimization doesn't help. I had a site which was hosted on dedicated 2.5GHZ/1GB RAM server and it was using almost 100% of CPU resources. After I optimized the scripts, CPU usage went down to 5%.
 
0
•••
NuPagady said:
After I optimized the scripts, CPU usage went down to 5%.
Optimization is an important factor now a days. We have a client whom had 2 servers with us (both Dual Xeon 2.4's, 2x80 gb hdd, 1 gb ram) whom optimized his site and now he can run his site off 1 dual xeon.
 
0
•••
Ok.. restart apache... sometimes apache carries processes in cache files and keeps them in the cpu if they are very active...

One thing i noted is that they were being run by the system... apache might need to be re configed
 
0
•••
Stop apache. Login to whm and click whm/mysql status. Check who is using the highest. Then click running processes. See who is using the highest. Kill them off and block users IP. Restart apache.

If that doesn't help ask the DC to do a full reboot. :)
 
0
•••
You call that high server load? You see my VPS...
 
0
•••
According to what you have shown in the screen shots, non of that is the cause of the hight cpu usage. Those are just visitors access port :80, apache, looking at a site on your vps, nothing else. And none of those have a high cpu usaged tagged to them.
If you want to see a more detailed look at the top process, login via ssh, and type "top"
 
0
•••
OulZac said:
According to what you have shown in the screen shots, non of that is the cause of the hight cpu usage. Those are just visitors access port :80, apache, looking at a site on your vps, nothing else. And none of those have a high cpu usaged tagged to them.
If you want to see a more detailed look at the top process, login via ssh, and type "top"
I just overlooked it again. Its not cpu load thats high. Usualy my root cpu load is about .20-.30 but nothing more. I have 2 Dual Xeon 2.8GHz clustered making 8CPU's, that could also be the reason. But what you are looking at is people looking at your site. Even if it said 30 cpu you're fine. Just check your control panel to see what your root load is. :)
 
0
•••
There are most likely some "leftover" processes. If you have a VPS, you should be able to reboot the VPS. If not, switch providers. Virtualization software works in such a way where individual "machines" can be restarted.
 
0
•••
mine is this
Current Time: Thursday, 26-Jan-2006 11:19:52 ICT
Restart Time: Thursday, 26-Jan-2006 11:09:52 ICT
Parent Server Generation: 0
Server uptime: 11 days, 9:36
Total accesses: 7049 - Total Traffic: 29.4 MB
CPU Usage: u31.0469 s5.38281 cu0 cs0 - 80.07% CPU load
11.7 requests/sec - 50.1 kB/second - 4368 B/request
40 requests currently being processed, 6 idle servers
do I qualify?

i did this:
login to ssh via putty.exe
nano or pico /usr/local/apache/conf/httpd.conf

set these parameters like this:
Timeout 60
KeepAlive On
MaxKeepAliveRequests 1024
KeepAliveTimeout 3
<IfModule prefork.c>
#StartServers 5
#MinSpareServers 5
#MaxSpareServers 10
MaxClients 2048
#MaxRequestsPerChild 0
ServerLimit 1024
StartServers 10
MinSpareServers 32
MaxSpareServers 64
MaxClients 1024
MaxRequestsPerChild 0
</IfModule>

then writout
then exit
then
/etc/init.d/httpd restart
that should do it.
HTH
 
0
•••
Try turning KeepAlive Off and reduce TimeOut setting. Or maybe it's time to upgrade to a dedicated server.
 
0
•••
Unstoppable Domains
Domain Recover
DomainEasy โ€” Live Options
  • The sidebar remains visible by scrolling at a speed relative to the pageโ€™s height.
Back