[Git][NTPsec/ntpsec][master] Add sample file for logrotate
Hal Murray
gitlab at mg.gitlab.com
Sat Dec 24 10:33:25 UTC 2016
Hal Murray pushed to branch master at NTPsec / ntpsec
Commits:
502e64a3 by Hal Murray at 2016-12-24T02:32:29-08:00
Add sample file for logrotate
- - - - -
1 changed file:
- + contrib/logrotate-ntpd
Changes:
=====================================
contrib/logrotate-ntpd
=====================================
--- /dev/null
+++ b/contrib/logrotate-ntpd
@@ -0,0 +1,18 @@
+# Adjust for your needs and install as /etc/logrotate.d/ntpd
+# This rotates monthly and kicks ntpd to start using the new file.
+# It inherits dateext and compress from /etc/logrotate.conf
+
+# If you are using SELinux, you will have to do something like:
+# cd /etc/logrotate.d/
+# sudo chcon --ref syslog ntpd
+# That may not work if selinux is not active. ????
+# ls -Z will show the results
+
+/var/log/ntpstats/ntpd.log {
+ monthly
+ rotate 9999
+ postrotate
+ /usr/bin/killall -HUP ntpd
+ endscript
+}
+
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/502e64a3097c0b2bbb6949cb6cd495d9503f3251
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ntpsec.org/pipermail/vc/attachments/20161224/a75228e4/attachment.html>
More information about the vc
mailing list