Debugging server load

I’m having some issues with my server, the cpu usage is constantly very high and causing the site to be slow. I’m on a fairly high-end server so it should more than be able to handle the amount of traffic I receive.

I’m guessing there is a bad script(s) somewhere that is causing these problems. I have been monitoring the mysql queries by running the “SHOW FULL PROCESSLIST” query.

Is there something similar I can do to show all php/http processes running on the server?

I know about the exec(“uptime”) command which gives me the current load but I would love to be able to show a list of all the processes and even the path to the script that is running on the sever. Is that possible?

I don’t have any suggestions, but is your server dedicated or shared?