I have syncthing running on two server systems, that is systems which run continuously without regular shutdowns or restarts. As a result the syncthing log file just gets bigger and bigger.
Is this likely to change (i.e. are there any plans to add some sort of log file rotation facility) or should I just have a script run by cron to deal with it?
It would also be nice if one could limit the log to just warnings or errors.
Syncthing logs to stdout by default. Log management is then left to the operator or packager. I typically pipe the output through something like
logger -t syncthing which then gets it into the regular syslog infrastructure. If you’re using systemd I’m sure it’s doing it’s own thing some other way.
There is currently no way to affect the log level, however the prefixes we use are regular so you could just do what I suggest above but pipe through
(Logs as streams of text are nice. You can do what you like with them.)
I’m running syncthing from /etc/rc.local with an explicit “-logfile” option so I guess I can filter it as I need. I suppose I could even use tee to split off the WARNING and FATAL messages to send me an E-Mail if/when something goes wrong.
Ah yes. The
-logfile was mostly added for Windows as there the concept of log data to stdout fits very badly with everything else.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.