This is actually a two part question. I've got a LAMP configuration and a web site that relies heavily on the error_log functionality built into PHP. The error log is growing rather large in size.
My first question is can I configure PHP (php.ini) to output these error messages to the Apache error log file?
If I can't, my second question is how can I rotate the PHP error log once a day? Is it possible to pipe the PHP error log to Cronolog (like you can in apache) or another log rotator? I'd like to stick with Cronolog if at all possible.
Thanks in advance.
I dont know what is your OS but at php.ini look for the line
error_log
Since you sent the error to apache you can now rotate the logs within it, if your apache is already being rotated by the syslog there is not need for this, but if it is not:
ErrorLog "|bin/rotatelogs /var/logs/errorlog.%Y-%m-%d-%H_%M_%S 5M"