Apache Usage Logs are cleared regularly?

befree33

Verified User
Joined
Feb 5, 2013
Messages
28
I'd like to know if the Apache Usage Logs at http://1234.23.234.12:2222/CMD_USER_STATS?domain=
are cleared regularly. I'm reading at http://www.webhostingtalk.com/showthread.php?t=867425 that they can increase server load.

Someone at the link above suggested removing the logs daily using the command below:

The apache logs are stored in:

/var/log/httpd/domains/domain.com.log
/var/log/httpd/domains/domain.com.error.log

so, create a file in /etc/logrotate.d/ with the following content:
Code:
/var/log/httpd/domains/*.log {
daily
}

I personally want to leave Apache logs as is because I think the system clears it after a period of time. Does anyone know how the logs are cleared and how often?
 
Cleaning logs is a bad idea. You need full logs to get proper historical data with stats programs like awstats/webalizer. I think thats a bunch of bs too...because the webserver is only appending to the file and its size has nothing to do with anything. Its not like its reading anything from the file at all. I have ran servers for over 15 years and I have never log rotated my webserver logs. Most of the people on wht have no clue what they are talking about. People think they install ubuntu once and they are a linux guru...ahaha.

The only reason I would ever logrotate is if I was desperate on space in /var and the logs were massive over several gb.
 
Last edited:
I personally have no intentions of messing with log files because they do show you errors and besides, the logs are kb not mb as the webhostingtalk op implied.
 
Cleaning logs is a bad idea.
Not always so with Exim logs; we recently had a client with a problem: exim wouldn't start.

The problem turned out to be that exim couldn't write to a log over 2GB in size, so it failed to start after mainlog reached 2GB.

Jeff
 
I was talking about apache. I am sure exim should be log rotated on a normal basis.
 
Back
Top