|
|||
|
httpd processes and server load
Hi,
Occasionally I see some resource intensive httpd processes which spike up the server load for a while. However it's hard to know which web site they belong to because they register under user 'nobody'. Anyone have any tips on finding out which site triggered the httpd process(es)? Thanks. |
|
|||
|
here is a way to find out
Take the process id from top then Code:
grep $(lsof -p PID | grep cwd | awk '{print $9}' | awk -F '/' '{ print $3 }') /etc/userdomains
hope that helps
__________________
http://www.linuxnetworkcare.com/services/cpanel.php Affordable Linux Server Managament Solution Order : https://secure.linuxnetworkcare.com Contact :[ Phone: 647-722-5303 MSN : xerophyte5@hotmail.com AIM : xerophytev] |
|
|||
|
Compliments to xerophyte
I would like to post my compliments to xerophyte also. Really amazingly helpful. I've been able to pinpoint and correct a number of faulty scripts on sites.
I am curious about the possibility of creating a log from this info for all processes running above 5 %CPU ? Would someone know how to do this ? thanks again for sharing xerophyte
|
|
|||
|
Quote:
|
|
|||
|
Quote:
2) When you note higher loads, it's a good idea to go ahead and login to WHM and check your "Apache Status" which will show you what files are currently being accessed on your web server and give you a clue where to look. 3) In SSH, you can follow up and go to /etc/httpd/domlogs and review the access logs for those sites you noted as the most active in WHM's "Apache Status" 4) If you run "top" in SSH, you can see which processes are the most active and type "m" to sort by memory usage or "p" to sort by cpu usage. The process ID shown in "ps" or in "top" can be matched up to the process ID in your apache status too. |
|
|||
|
apache load
HI,
Apache is taking load more then 600 cpu but apache status or proc show like tihs. rwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / lrwxrwxrwx 1 root root 0 May 1 06:18 cwd -> / how to trace such load?
__________________
!! IF YOU DO FOR OTHERS, OTHERS WILL DO FOR YOU !! ![]() Thank you..... ................... |
![]() |
| Thread Tools | |
| Display Modes | |
|
|