From 31c8d8214fa82e857c8eb4889b14d30c68e36dd6 Mon Sep 17 00:00:00 2001 From: Daniel Earl Poirier Date: Tue, 19 Oct 2010 15:12:11 +0000 Subject: [PATCH] Add warning about using rotatelogs filename formats with not enough granularity. PR46318. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1024263 13f79535-47bb-0310-9956-ffa450edef68 --- docs/manual/programs/rotatelogs.xml | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/docs/manual/programs/rotatelogs.xml b/docs/manual/programs/rotatelogs.xml index 9d55ec3895..a1f6c20a66 100644 --- a/docs/manual/programs/rotatelogs.xml +++ b/docs/manual/programs/rotatelogs.xml @@ -84,7 +84,7 @@ close actions.
logfile
-
The path plus basename of the logfile. If logfile +

The path plus basename of the logfile. If logfile includes any '%' characters, it is treated as a format string for strftime(3). Otherwise, the suffix .nnnnnnnnnn is automatically added and is the time in @@ -93,7 +93,17 @@ start time from the beginning of the current period. For example, if a rotation time of 86400 is specified, the hour, minute, and second fields created from the strftime(3) format will all be zero, referring to the beginning of the current 24-hour -period (midnight).

+period (midnight).

+

When using strftime(3) filename formatting, +be sure the log file format has enough granularity to produce +a different file name each time the logs are rotated. Otherwise +rotation will overwrite the same file instead of starting a new +one. For example, if logfile was +/var/logs/errorlog.%Y-%m-%d with log rotation at 5 +megabytes, but 5 megabytes was reached twice in the same day, the +same log file name would be produced and log rotation would keep +writing to the same file.

+
rotationtime
-- 2.50.1