Skip to content

Commit

Permalink
fix: default value for logfile rotation interval
Browse files Browse the repository at this point in the history
The unit of 'd' is not a valid time.Duration unit. Due to the more
strict parsing of durations, this is now correctly failing. Previously
using a value of '1d' would fail silently. If a user wishes to use a
value of days, they need to convert to hours and use '24h' for example
of one day.

Fixes: #10882
  • Loading branch information
powersj committed Mar 24, 2022
1 parent 828b040 commit 095def4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion etc/telegraf.conf
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
## The logfile will be rotated after the time interval specified. When set
## to 0 no time based rotation is performed. Logs are rotated only when
## written to, if there is no log activity rotation may be delayed.
# logfile_rotation_interval = "0d"
# logfile_rotation_interval = "0h"

## The logfile will be rotated when it becomes larger than the specified
## size. When set to 0 no size based rotation is performed.
Expand Down

0 comments on commit 095def4

Please sign in to comment.