After upgrading from 2.2.7 to Apache 2.4.9 seems that logging doesn't work properly. Only things which are logged are modsecurity and fcgid events, but nothing from Apache like file not found errors. Checking the Apache error_log, specifically after a restart I've noticed this:
[Sun Jul 13 05:16:10.482003 2014] [log_config:warn] [pid 30283:tid 140001085970176] (32)Broken pipe: [client 125.166.227.47:26260] AH00646: Error writing to |/usr/local/cpanel/bin/splitlogs --main=server.mysite.com --suffix=-bytes_log
[Sun Jul 13 05:16:10.482047 2014] [log_config:warn] [pid 30283:tid 140001085970176] (32)Broken pipe: [client 125.166.227.47:26260] AH00646: Error writing to |/usr/local/cpanel/bin/splitlogs --main=server.mysite.com --mainout=/usr/local/apache/logs/access_log
I haven't got a clue what "broken pipe" means. I have piped logging enabled (which was enabled before upgrading Apache). Tried disabling it but got the same thing and nothing logged. Checked httpd.conf file at the log section comparing with the old conf file but can't seem to find anything different:
<IfModule mod_log_config.c>
LogFormat "%v:%p %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combinedvhost
LogFormat "%v %{%s}t %I .\n%v %{%s}t %O ." bytesvhost
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common
LogFormat "%{Referer}i -> %U" referer
LogFormat "%{User-agent}i" agent
CustomLog "|/usr/local/cpanel/bin/splitlogs --main=server.mysite.com --suffix=-bytes_log" bytesvhost
CustomLog "|/usr/local/cpanel/bin/splitlogs --main=server.mysite.com --mainout=/usr/local/apache/logs/access_log" combinedvhost
</IfModule>
I'd appreciate it if anyone could shed some light on this. Thanks.
UPDATE: Broken file error have been eliminated by changing perms to 777 for access_log and error_log. Main problem still persists though, as in none of Apache related errors (404, 403 etc.) are getting logged.