May 22, 2009
On WHM you can configure that afer stats run, delete domlog of the domain, this is good to dont get out of disk space, the problem is that on my country you need to save access log of apache for some months by law.

What i would like is to move it to another folder.

At this time i have a script that copy al logs at midnight, and the problem is that stats only have access log from midnight to the time that is executed so, only few hours, so what i'm trying to do is to move the log after is processed by awstats (i only use this stats program) to another folder, and my scipt could copy after.

I have opened a ticket with cpanel support but they dont support this things, but said me where i need to start customizing and is:

/usr/local/cpanel/Cpanel/Logd.pm in function "dologs", around line 424.

Anyone could help me.



Well-Known Member
Sep 25, 2007
Cpanel already has an option built in to save the logs. It creates a folder called log or logs in your home directory where it stores the apache domlogs in a compressed file. You can enable this by clicking on raw access logs and then:

Archive Logs in your home directory at the end of each stats run