Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am running Apache2 with Froxlor, so every customer gets their own access and error log in /var/customers/logs.

Now, is it possible to keep this functionality while also having a global access and error log the good old /var/log way that contains all traffic and errors?

I have tried defining a CustomLog in the global apache2.conf to no avail.

share|improve this question

1 Answer 1

up vote 0 down vote accepted

The solution is to add another CustomLog line to every vhost. Each pointing to the very same file.

Setting this up is a little bit of effort since you may have to edit a lot of vhost configurations but afterwards it works like a charm.

Example lines for a <VirtualHost ...> segment:

CustomLog /var/www/web0123/access.log combined
CustomLog ${APACHE_LOG_DIR}/access.log vhost_combined

APACHE_LOG_DIR is optional and may be defined in the envvars configuration file.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.