From: Daniel Earl Poirier The path plus basename of the logfile. If logfile
includes any '%' characters, it is treated as a format string for
logfile
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).
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