PDA

View Full Version : Accesslog daily rotation...


Ben
1st August 2006, 10:38
Referring to that thread: http://www.howtoforge.com/forums/showthread.php?p=35464

Well I took a look at both scripts...
at first I would say the mainrproblem comes from the logs.php cause of eventually opening a file > 2GB....

But at first why does the logs.php opens a file like ispconfig_access_log_... instead of the symlink because that is the actual one?

Does the cron run logs.php every 12 hours or why do you reduce time() with 43200 secs?


Edit:
What does these lines do, they only exists once...

$tag = date("d", (time() - 43200));
$monat = date("m", (time() - 43200));
$jahr = date("Y", (time() - 43200));


EDIT2: My idea would be to change the logscript, rotating in the "monthdir"... the webalizerscript than scans for this files an calls webalizer for each file. Or are there any problems with that idea?

fobicodam
1st August 2006, 11:50
This works great on my servers.

http://www.howtoforge.com/forums/showthread.php?t=5763

The problem will persist when some individual domain reach the 2Gb limit log file...

Ben
1st August 2006, 11:58
Ah ok, so there is no more need to do anything here...