|
|
6e16f6 |
diff -up ntp-4.2.6p5/html/miscopt.html.logdefault ntp-4.2.6p5/html/miscopt.html
|
|
|
6e16f6 |
--- ntp-4.2.6p5/html/miscopt.html.logdefault 2009-12-09 08:36:36.000000000 +0100
|
|
|
6e16f6 |
+++ ntp-4.2.6p5/html/miscopt.html 2014-01-03 15:08:11.947681966 +0100
|
|
|
6e16f6 |
@@ -56,11 +56,11 @@
|
|
|
6e16f6 |
While not strictly a security function, the Autokey protocol provides means to securely retrieve the current or updated leapsecond values from a server.
|
|
|
6e16f6 |
<tt>logconfig configkeyword</tt>
|
|
|
6e16f6 |
This command controls the amount and type of output written to the system <tt>syslog</tt> facility or the alternate <tt>logfile</tt> log file. All <tt>configkeyword</tt> keywords can be prefixed with <tt>=</tt>, <tt>+</tt> and <tt>-</tt>, where <tt>=</tt> sets the <tt>syslogmask</tt>, <tt>+</tt> adds and <tt>-</tt> removes messages. <tt>syslog messages</tt> can be controlled in four classes (<tt>clock</tt>, <tt>peer</tt>, <tt>sys</tt> and <tt>sync</tt>). Within these classes four types of messages can be controlled: informational messages (<tt>info</tt>), event messages (<tt>events</tt>), statistics messages (<tt>statistics</tt>) and status messages (<tt>status</tt>).
|
|
|
6e16f6 |
- Configuration keywords are formed by concatenating the message class with the event class. The <tt>all</tt> prefix can be used instead of a message class. A message class may also be followed by the <tt>all</tt> keyword to enable/disable all messages of the respective message class. By default, <tt>logconfig</tt> output is set to <tt>allsync</tt>.
|
|
|
6e16f6 |
+ Configuration keywords are formed by concatenating the message class with the event class. The <tt>all</tt> prefix can be used instead of a message class. A message class may also be followed by the <tt>all</tt> keyword to enable/disable all messages of the respective message class. By default, <tt>logconfig</tt> output is set to <tt>=syncall +sysevents +sysstatus</tt>.
|
|
|
6e16f6 |
Thus, a minimal log configuration could look like this:
|
|
|
6e16f6 |
- <tt>logconfig=syncstatus +sysevents</tt>
|
|
|
6e16f6 |
+ <tt>logconfig =syncstatus +sysevents</tt>
|
|
|
6e16f6 |
This would just list the synchronizations state of <tt>ntpd</tt> and the major system events. For a simple reference server, the following minimum message configuration could be useful:
|
|
|
6e16f6 |
- <tt>logconfig allsync +allclock</tt>
|
|
|
6e16f6 |
+ <tt>logconfig =syncall +clockall</tt>
|
|
|
6e16f6 |
This configuration will list all clock information and synchronization information. All other events and messages about peers, system events and so on is suppressed.
|
|
|
6e16f6 |
<tt>logfile logfile</tt>
|
|
|
6e16f6 |
This command specifies the location of an alternate log file to be used instead of the default system <tt>syslog</tt> facility. This is the same operation as the <tt>-l </tt>command line option.
|
|
|
6e16f6 |
diff -up ntp-4.2.6p5/ntpd/ntp_config.c.logdefault ntp-4.2.6p5/ntpd/ntp_config.c
|
|
|
6e16f6 |
--- ntp-4.2.6p5/ntpd/ntp_config.c.logdefault 2011-12-01 03:55:17.000000000 +0100
|
|
|
6e16f6 |
+++ ntp-4.2.6p5/ntpd/ntp_config.c 2014-01-03 15:05:44.293553494 +0100
|
|
|
6e16f6 |
@@ -3835,7 +3835,7 @@ getconfig(
|
|
|
6e16f6 |
|
|
|
6e16f6 |
#endif /* SYS_WINNT */
|
|
|
6e16f6 |
res_fp = NULL;
|
|
|
6e16f6 |
- ntp_syslogmask = NLOG_SYNCMASK; /* set more via logconfig */
|
|
|
6e16f6 |
+ ntp_syslogmask = NLOG_SYNCMASK | NLOG_SYSEVENT | NLOG_SYSSTATUS; /* set more via logconfig */
|
|
|
6e16f6 |
|
|
|
6e16f6 |
/*
|
|
|
6e16f6 |
* install a non default variable with this daemon version
|