Rob Reisenwitz

Registered
Jan 12, 2017
2
0
1
Sparks Nevada USA
cPanel Access Level
Root Administrator
I need to configure Apache to create a duplicate access and error log.

I used to be able to do the following but this no longer works:

To make a separate set of log files without messing with these
/var/cpanel/templates/apache2/main.default
/var/cpanel/templates/apache2/main.local
/var/cpanel/templates/apache2/vhost.default
/var/cpanel/templates/apache2/vhost.local
/var/cpanel/templates/apache2/ssl_vhost.default
/var/cpanel/templates/apache2/ssl_vhost.local

STEP 1

Create the file:
pico /usr/local/apache/conf/userdata/extralogs.conf
pico /usr/local/apache/conf/extralogs.conf

STEP 2

Add:
ErrorLog /home/hmwhmw42/public_html/fillspot/errorhmw42.log
CustomLog /home/hmwhmw42/public_html/fillspot/accesshmw42.log "%h %l %u %t \"%r\" %s %b %v \"%{Referer}i\" \"%{User-agent}i\"

STEP 3

Restart Apache.
service httpd restart
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,904
2,219
463
Hello,

Could you verify if this system uses EasyApach 3, or EasyApache 4?

Thank you.