I have a CentOS 5 system with:
[root@wikisrv-01 wiki]# rpm -q httpd
httpd-2.2.3-11.el5_1.centos.3
[root@wikisrv-01 wiki]# rpm -q php
php-5.1.6-15.el5
I want to troubleshoot a PHP problem, and am trying to get PHP logs.
In php.ini, I have:
log_errors = On
error_reporting = E_ALL
error_log = /var/log/php.log
I touched /var/log/php.log, chowned it to apache, and restarted httpd But nothing is being written to /var/log/php.log or /var/log/httpd/error_log or anywhere else that I can find. What do I need to do to get PHP logs?
Obtaining PHP logs?
Re: Obtaining PHP logs?
Have a look at the apache logs (/var/www/logs/httpd/error_log), I can usually find any PHP errors listed in there.
Update: sorry, I now see you've already looked there!
Update: sorry, I now see you've already looked there!
-
- Posts: 73
- Joined: 2008/09/19 19:03:37
Re: Obtaining PHP logs?
You do not need to modify the error_log option path, just leave the way it is
; Log errors to specified file.
;error_log = filename
all php errors are written to the error_log file in
/etc/httpd/logs/error_log
by default
; Log errors to specified file.
;error_log = filename
all php errors are written to the error_log file in
/etc/httpd/logs/error_log
by default