]> arthur.barton.de Git - netdata.git/blobdiff - system/netdata.logrotate.in
have default logrotate file work in all cases - even if netdata is not managed by...
[netdata.git] / system / netdata.logrotate.in
index 763eb09c930d66aa1d1d5ee25fc037d7c6419fff..e77d5ff72bf0b3bc289c32ed67f4ec97020bd47a 100644 (file)
@@ -6,10 +6,16 @@
        delaycompress
        notifempty
        sharedscripts
-       postrotate
-               if service netdata status > /dev/null ; then \
-                       service netdata restart > /dev/null; \
-               fi;
-       endscript
+       #
+       # if you add netdata to your init.d/system.d
+       # comment su & copytruncate and uncomment postrotate
+       # to have netdata restart when logs are rotated
+       su netdata
+       copytruncate
+       #
+       #postrotate
+       #       if service netdata status > /dev/null ; then \
+       #               service netdata restart > /dev/null; \
+       #       fi;
+       #endscript
 }
-