From 3e1dc801b0d96e732b295c8a90383de56ac488f5 Mon Sep 17 00:00:00 2001 From: Miroslav Lichvar Date: Wed, 21 May 2014 12:08:10 +0200 Subject: [PATCH] conf: change default corrtimeratio to 3.0 This improves the overall frequency accuracy of the clock at a slight cost in the time accuracy. --- chrony.texi.in | 17 ++++++++--------- conf.c | 2 +- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/chrony.texi.in b/chrony.texi.in index 9cc87b75..eee4b845 100644 --- a/chrony.texi.in +++ b/chrony.texi.in @@ -1513,9 +1513,9 @@ the password command automatically. @subsection corrtimeratio When @code{chronyd} makes a time correction, it controls how quickly the system clock is slewed (so far only on Linux). This rate -temporarily affects the frequency error of the system clock. +affects the frequency error of the system clock. -The @code{corrtimeratio} directive controls the ratio between the +The @code{corrtimeratio} directive sets the ratio between the duration in which the clock is slewed for an average correction according to the source history and the interval in which the corrections are done (usually the NTP polling interval). Corrections @@ -1523,22 +1523,21 @@ larger than the average take less time and smaller corrections take more time, the amount of the correction and the correction time are inversely proportional. -Increasing @code{corrtimeratio} makes the overall frequency error of -the system clock smaller, but increases the overall time error as -the corrections will take longer. +Increasing @code{corrtimeratio} improves the overall frequency error +of the system clock, but increases the overall time error as the +corrections take longer. -By default, the ratio is 1, which means the duration of an average -correction will be close to the update interval. +By default, the ratio is set to 3, the time accuracy of the clock is +preferred over its frequency accuracy. The syntax is @example -corrtimeratio 10 +corrtimeratio 100 @end example The current remaining correction is shown in the @code{tracking} report (@pxref{tracking command}) as the @code{System time} value. - @c }}} @c {{{ deny @node deny directive diff --git a/conf.c b/conf.c index e19c5d95..5e419d45 100644 --- a/conf.c +++ b/conf.c @@ -86,7 +86,7 @@ static char *drift_file = NULL; static char *rtc_file = NULL; static unsigned long command_key_id; static double max_update_skew = 1000.0; -static double correction_time_ratio = 1.0; +static double correction_time_ratio = 3.0; static double max_clock_error = 1.0; /* in ppm */ static double reselect_distance = 1e-4; -- 2.47.2