Logging all php scripts that are accessed

Karandras

[H]ard|Gawd
Joined
Feb 16, 2001
Messages
1,873
Hey,

Here is the problem. The company I work for is running a version of plesk that is outdated and needs to be upgraded. We are working on that upgrade however in the mean time the server has been compromised a few times with spam scripts and such. It's all php that's causing the problem so I was wanting to log all scripts that are run on the server and I'll rotate the file daily to avoid it getting too big.

Any ideas on what I can put into the php.ini to log this?

Thanks!
 
The web server will already have this information available. You are looking for the access logs, which you can then parse later.
 
This is true and probably the best way to find the problem script. I'm trying to track down a script on a couple sites that is causing high CPU (sever going from 0.5 load to 15).

Is there a better way to find that? I've tried ps aux but it just shows the php-cgi process and not the script path...
 
Back
Top