diff options
Diffstat (limited to '')
| -rw-r--r-- | net/openntpd/files/patch-ntpd.c | 12 | ||||
| -rw-r--r-- | net/openntpd/files/patch-ntpd.conf.5 | 52 |
2 files changed, 42 insertions, 22 deletions
diff --git a/net/openntpd/files/patch-ntpd.c b/net/openntpd/files/patch-ntpd.c index 92cefab02d39..e47d20c1ac33 100644 --- a/net/openntpd/files/patch-ntpd.c +++ b/net/openntpd/files/patch-ntpd.c @@ -2,18 +2,18 @@ $FreeBSD$ Drift file in ppm for compatibility with reference ntpd. ---- ntpd.c.orig 2009-08-01 22:17:42.000000000 +0200 -+++ ntpd.c 2009-08-01 22:18:51.000000000 +0200 -@@ -449,7 +449,7 @@ readfreq(void) +--- ntpd.c.orig 2009-11-23 20:34:47.000000000 +0100 ++++ ntpd.c 2009-11-23 20:36:38.000000000 +0100 +@@ -457,7 +457,7 @@ readfreq(void) log_warn("adjfreq failed"); else if (current == 0) { if (fscanf(fp, "%le", &d) == 1) - ntpd_adjfreq(d, 0); + ntpd_adjfreq(d / 1e6, 0); + else + log_warnx("can't read %s", DRIFTFILE); } - fclose(fp); - } -@@ -470,7 +470,7 @@ writefreq(double d) +@@ -480,7 +480,7 @@ writefreq(double d) return 0; } diff --git a/net/openntpd/files/patch-ntpd.conf.5 b/net/openntpd/files/patch-ntpd.conf.5 index c323ed28e76e..94600766d98d 100644 --- a/net/openntpd/files/patch-ntpd.conf.5 +++ b/net/openntpd/files/patch-ntpd.conf.5 @@ -1,16 +1,7 @@ $FreeBSD$ ---- ntpd.conf.5.orig 2009-08-01 21:41:54.000000000 +0200 -+++ ntpd.conf.5 2009-08-01 21:47:49.000000000 +0200 -@@ -28,7 +28,7 @@ configuration file. - The optional - .Ic weight - keyword permits finer control over the relative importance --of time sources (servers or sensor devices). -+of time sources. - Weights are specified in the range 1 to 10; - if no weight is given, - the default is 1. -@@ -70,51 +70,6 @@ or +--- ntpd.conf.5.orig 2009-11-23 21:03:30.000000000 +0100 ++++ ntpd.conf.5 2009-11-23 21:12:27.000000000 +0100 +@@ -59,62 +59,6 @@ or listen on 127.0.0.1 listen on ::1 .Ed @@ -36,18 +27,29 @@ $FreeBSD$ -For example: -.Bd -literal -offset indent -sensor * --sensor udcf0 +-sensor nmea0 -.Ed -.Pp -An optional correction in microseconds can be given to compensate -for the sensor's offset. -The maximum correction is 127 seconds. --For example, if a DCF77 receiver is lagging 15ms behind +-For example, if a DCF77 receiver is lagging 70ms behind -actual time: -.Bd -literal -offset indent --sensor udcf0 correction 15000 +-sensor udcf0 correction 70000 -.Ed -.Pp +-The optional +-.Ic weight +-keyword permits finer control over the relative importance +-of time sources (servers or sensor devices). +-Weights are specified in the range 1 to 10; +-if no weight is given, +-the default is 1. +-A server with a weight of 5, for example, +-will have five times more influence on time offset calculation +-than a server with a weight of 1. +-.Pp -An optional reference ID string - up to 4 ASCII characters - can be -given to publish the sensor type to clients. -RFC 2030 suggests some common reference identifiers, but new identifiers @@ -57,11 +59,29 @@ $FreeBSD$ -will use a generic reference ID. -For example: -.Bd -literal -offset indent --sensor msts0 refid GPS +-sensor nmea0 refid GPS -.Ed .It Xo Ic server Ar address .Op Ic weight Ar weight-value .Xc +@@ -139,6 +83,17 @@ server ntp.example.org weight 1 + To provide redundancy, it is good practice to configure multiple servers. + In general, best accuracy is obtained by using servers that have a low + network latency. ++.Pp ++The optional ++.Ic weight ++keyword permits finer control over the relative importance ++of time sources. ++Weights are specified in the range 1 to 10; ++if no weight is given, ++the default is 1. ++A server with a weight of 5, for example, ++will have five times more influence on time offset calculation ++than a server with a weight of 1. + .It Xo Ic servers Ar address + .Op Ic weight Ar weight-value + .Xc @@ -157,15 +112,14 @@ servers pool.ntp.org .Ed .El |
