Log rotation
#7360
Replies: 1 comment 1 reply
-
|
You should use I think |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I am using zigbee2mqtt with a few CC2531 chips as coordinator and end devices. My application requires that my logging (in Linux, the files in /opt/zigbee2mqtt/data/) must last for multiple days consecutively. To this end, I am using the log_rotation feature.
However, I have noticed that the rotation of file names goes only up to 2 (that is, log.txt, then log1.txt, then log2.txt, then back to log.txt) And soI start losing my earlier data stored in log.txt.
As I would like to keep the logging running for several days (requiring at least 5 or 6 files, of greater than 9MB each) I need the log rotation to extend up to log3.txt, log4.txt,... etc.
Is there an additional setting somewhere I can enable to ensure that the log rotation continue for a longer period before reverting back to overwriting log.txt? Or should I make some sort of bash script to make sure I copy the files periodically before they are overwritten by the log rotation?
Any help is much appreciated,
Aaron
Beta Was this translation helpful? Give feedback.
All reactions