]> git.ipfire.org Git - thirdparty/chrony.git/log
thirdparty/chrony.git
9 years agosourcestats: report asymmetry in statistics log
Miroslav Lichvar [Wed, 10 Aug 2016 14:17:51 +0000 (16:17 +0200)] 
sourcestats: report asymmetry in statistics log

9 years agosourcestats: correct offsets with asymmetric network jitter
Miroslav Lichvar [Wed, 10 Aug 2016 13:51:51 +0000 (15:51 +0200)] 
sourcestats: correct offsets with asymmetric network jitter

Estimate asymmetry of network jitter on the path to the source as a
slope of offset against network delay in multiple linear regression. If
the asymmetry is significant and its sign doesn't change frequently, the
measured offsets (which are used later to estimate the offset and
frequency of the clock) are corrected to correspond to the minimum
network delay. This can significantly improve the accuracy and stability
of the estimated offset and frequency.

9 years agosourcestats: add debug message for regression results
Miroslav Lichvar [Wed, 10 Aug 2016 13:10:11 +0000 (15:10 +0200)] 
sourcestats: add debug message for regression results

9 years agoregress: add linear regression with two independent variables
Miroslav Lichvar [Tue, 9 Aug 2016 13:28:32 +0000 (15:28 +0200)] 
regress: add linear regression with two independent variables

9 years agosourcestats: extend array holding peer delays
Miroslav Lichvar [Mon, 8 Aug 2016 13:51:51 +0000 (15:51 +0200)] 
sourcestats: extend array holding peer delays

Keep the same number of peer delays as offsets. This will be needed when
peer delay is included in offset correction.

9 years agoregress: save arrays of constants in single-precision
Miroslav Lichvar [Thu, 4 Aug 2016 11:59:42 +0000 (13:59 +0200)] 
regress: save arrays of constants in single-precision

No need to waste space on double precision. Also, declare them as const.

9 years agorename 'Mac OS X' to 'macOS'
Bryan Christianson [Thu, 4 Aug 2016 08:08:07 +0000 (20:08 +1200)] 
rename 'Mac OS X' to 'macOS'

From the the release of macOS Sierra (Version 10.12) the Macintosh
operating system is called 'macOS'

9 years agontp: reset tentative flag only when sample was accumulated
Miroslav Lichvar [Wed, 3 Aug 2016 10:13:22 +0000 (12:13 +0200)] 
ntp: reset tentative flag only when sample was accumulated

When selecting sources from a pool, ignore responses which didn't
produce a new sample. Sources with acceptable delay (as configured by
the maxdelay* options) should be prefered.

9 years agontp: close client sockets sooner with unsynchronised sources
Miroslav Lichvar [Wed, 3 Aug 2016 10:07:43 +0000 (12:07 +0200)] 
ntp: close client sockets sooner with unsynchronised sources

When a valid packet is received from an unsynchronised source (i.e. only
a test of leap, stratum or root distance failed), there is no point in
waiting for another packet or the RX timeout, and the client socket can
be immediately closed.

9 years agotest: add 010-multrecv
Miroslav Lichvar [Tue, 2 Aug 2016 11:44:57 +0000 (13:44 +0200)] 
test: add 010-multrecv

9 years agontp: add support for recvmmsg()
Miroslav Lichvar [Tue, 2 Aug 2016 10:17:15 +0000 (12:17 +0200)] 
ntp: add support for recvmmsg()

This is used to read multiple packets with one system call. It should
work on Linux and NetBSD.

9 years agoconfigure: include config.h in test code
Miroslav Lichvar [Tue, 2 Aug 2016 10:15:56 +0000 (12:15 +0200)] 
configure: include config.h in test code

9 years agontp: rework receiving messages
Miroslav Lichvar [Mon, 1 Aug 2016 15:25:43 +0000 (17:25 +0200)] 
ntp: rework receiving messages

Allocate buffers for received messages on heap instead of stack and
prepare the code for receiving multiple messages at the same time.

9 years agontp: align buffers for control messages
Miroslav Lichvar [Mon, 1 Aug 2016 14:57:09 +0000 (16:57 +0200)] 
ntp: align buffers for control messages

10 years agontp: add support for MS-SNTP authentication in Samba
Miroslav Lichvar [Wed, 27 Jul 2016 12:09:32 +0000 (14:09 +0200)] 
ntp: add support for MS-SNTP authentication in Samba

Add support for authenticating MS-SNTP responses in Samba (ntp_signd).
Supported is currently only the old MS-SNTP authenticator field. It's
disabled by default. It can be enabled with the --enable-ntp-signd
configure option and the ntpsigndsocket directive, which specifies the
location of the Samba ntp_signd socket.

10 years agontp: detect MS-SNTP packets
Miroslav Lichvar [Wed, 27 Jul 2016 11:28:01 +0000 (13:28 +0200)] 
ntp: detect MS-SNTP packets

When a received packet fails to authenticate, check if the digest
contains zeroes and treat it as an MS-SNTP packet with authenticator or
extended authenticator field. For now, discard these packets, i.e. don't
respond with a crypto-NAK.

10 years agontp: refactor selection of authentication mode
Miroslav Lichvar [Fri, 22 Jul 2016 13:41:42 +0000 (15:41 +0200)] 
ntp: refactor selection of authentication mode

Replace the flag that enables authentication using a symmetric key with
an enum. Specify crypto-NAK as a special mode used for responses instead
of relying on zero key ID. Also, rework check_packet_auth() to always
save the mode and key ID.

10 years agontp: check for extension fields only in NTPv4 packets
Miroslav Lichvar [Wed, 20 Jul 2016 10:47:38 +0000 (12:47 +0200)] 
ntp: check for extension fields only in NTPv4 packets

10 years agodoc: improve description of chronyc -n option
Miroslav Lichvar [Tue, 19 Jul 2016 13:43:32 +0000 (15:43 +0200)] 
doc: improve description of chronyc -n option

10 years agoclient: indicate truncated addresses/hostnames
Miroslav Lichvar [Tue, 19 Jul 2016 13:37:23 +0000 (15:37 +0200)] 
client: indicate truncated addresses/hostnames

Add symbol > to the end of the resolved hostname or address when it's
truncated.

10 years agoclient: truncate long hostnames in clients output
Miroslav Lichvar [Tue, 19 Jul 2016 13:15:40 +0000 (15:15 +0200)] 
client: truncate long hostnames in clients output

10 years agoclient: print intervals in seconds up to 1200 seconds
Miroslav Lichvar [Tue, 19 Jul 2016 12:55:29 +0000 (14:55 +0200)] 
client: print intervals in seconds up to 1200 seconds

This covers random variations in the default maximum polling interval.

10 years agosources: optimize SRC_ReportSource() a bit
Miroslav Lichvar [Tue, 19 Jul 2016 13:57:16 +0000 (15:57 +0200)] 
sources: optimize SRC_ReportSource() a bit

Remove unnecessary memset() call and use the default case of the switch
to report the unreachable state.

10 years agoaddressing: pad IPAddr struct explicitly
Miroslav Lichvar [Tue, 19 Jul 2016 13:01:56 +0000 (15:01 +0200)] 
addressing: pad IPAddr struct explicitly

10 years agoutil: round up when converting to 32-bit NTP values
Miroslav Lichvar [Tue, 19 Jul 2016 12:46:17 +0000 (14:46 +0200)] 
util: round up when converting to 32-bit NTP values

NTP clients shouldn't get root delay and dispersion smaller than the
server's values.

10 years agontp: add offset option
Miroslav Lichvar [Tue, 28 Jun 2016 13:27:44 +0000 (15:27 +0200)] 
ntp: add offset option

Add offset option to the server/pool/peer directive. It specifies a
correction which will be applied to offsets measured with the NTP
source. It's particularly useful to compensate for a known asymmetry in
network delay or timestamping errors.

10 years agoclient: rework error printing for unsupported source options
Miroslav Lichvar [Tue, 28 Jun 2016 11:26:09 +0000 (13:26 +0200)] 
client: rework error printing for unsupported source options

10 years agoconf: fix parsing of refclock directive
Miroslav Lichvar [Mon, 27 Jun 2016 12:38:51 +0000 (14:38 +0200)] 
conf: fix parsing of refclock directive

Don't accept refclock directive which has as the last argument an option
that requires a value.

10 years agocmdparse: remove CPS_Status
Miroslav Lichvar [Mon, 27 Jun 2016 11:38:55 +0000 (13:38 +0200)] 
cmdparse: remove CPS_Status

Remove command and option specific error codes. Return zero on any
failure.

10 years agocmdparse: refactor CPS_ParseNTPSourceAdd()
Miroslav Lichvar [Mon, 27 Jun 2016 11:36:37 +0000 (13:36 +0200)] 
cmdparse: refactor CPS_ParseNTPSourceAdd()

10 years agosched: add support for output file event
Miroslav Lichvar [Wed, 22 Jun 2016 13:14:25 +0000 (15:14 +0200)] 
sched: add support for output file event

This allows waiting for non-blocking write operations.

10 years agosched: don't keep prepared fd_set
Miroslav Lichvar [Wed, 22 Jun 2016 12:21:33 +0000 (14:21 +0200)] 
sched: don't keep prepared fd_set

Instead of copying a prepared fd_set to the fd_set used by select(),
fill it from scratch according to the array of file handlers before each
select() call. This should make the code simpler and save some memory
when other events are supported.

10 years agosched: rework file handling API
Miroslav Lichvar [Thu, 16 Jun 2016 14:47:40 +0000 (16:47 +0200)] 
sched: rework file handling API

Replace SCH_*InputFileHandler() functions with more general
SCH_*FileHandler(), where events are specified as a new parameter and
which will later support other file events, e.g. file ready for ouput
and exception.

The file handlers have two new parameters: file descriptor and event.

10 years agologging: fix LOG_MESSAGE macro to not use semicolon
Miroslav Lichvar [Thu, 16 Jun 2016 15:15:04 +0000 (17:15 +0200)] 
logging: fix LOG_MESSAGE macro to not use semicolon

10 years agodoc: update NEWS 2.4
Miroslav Lichvar [Mon, 6 Jun 2016 14:48:23 +0000 (16:48 +0200)] 
doc: update NEWS

10 years agodoc: update README
Miroslav Lichvar [Mon, 6 Jun 2016 14:47:25 +0000 (16:47 +0200)] 
doc: update README

10 years agodoc: add question about reference ID to FAQ
Miroslav Lichvar [Tue, 7 Jun 2016 09:08:47 +0000 (11:08 +0200)] 
doc: add question about reference ID to FAQ

10 years agodoc: improve chronyc man page
Stephen Wadeley [Sun, 5 Jun 2016 19:01:48 +0000 (21:01 +0200)] 
doc: improve chronyc man page

- fix redundant words, word order, articles, consistency, typos
- avoid slashes, contractions, `may`, dashes in running text
- add Oxford commas
- use colon before examples

10 years agodoc: improve chrony.conf man page
Stephen Wadeley [Fri, 3 Jun 2016 07:33:34 +0000 (09:33 +0200)] 
doc: improve chrony.conf man page

- fix word order, articles, consistency, and some typos
- avoid slashes, contractions, `may`, dashes in running text
- use colons before example and code blocks
- add Oxford commas

10 years agoclient: fix compiler warnings on NetBSD
Miroslav Lichvar [Tue, 7 Jun 2016 07:34:20 +0000 (09:34 +0200)] 
client: fix compiler warnings on NetBSD

10 years agoreference: suppress orphan option in special reference modes
Miroslav Lichvar [Mon, 30 May 2016 11:59:01 +0000 (13:59 +0200)] 
reference: suppress orphan option in special reference modes

This allows a server that will become the orphan source to initialize
its time with the initstepslew directive from the current orphan source
or its clients.

10 years agodoc: improve answer in FAQ for firewall issue
Miroslav Lichvar [Mon, 23 May 2016 07:00:42 +0000 (09:00 +0200)] 
doc: improve answer in FAQ for firewall issue

10 years agoexamples: update chrony.spec
Miroslav Lichvar [Tue, 17 May 2016 15:57:33 +0000 (17:57 +0200)] 
examples: update chrony.spec

10 years agotest: extend 105-ntpauth
Miroslav Lichvar [Tue, 17 May 2016 10:55:54 +0000 (12:55 +0200)] 
test: extend 105-ntpauth

10 years agontp: fix definition of minimum and maximum MAC length
Miroslav Lichvar [Tue, 17 May 2016 10:49:52 +0000 (12:49 +0200)] 
ntp: fix definition of minimum and maximum MAC length

The NTP_*_MAC_LENGTH macros didn't include the key ID, which caused the
NTP authentication check to ignore MACs with 512-bit hashes (SHA512,
WHIRLPOOL).

This was broken since update to NTPv4.

10 years agodoc: update NEWS 2.4-pre1
Miroslav Lichvar [Mon, 16 May 2016 09:08:00 +0000 (11:08 +0200)] 
doc: update NEWS

10 years agomake_release: update for changes in documentation
Miroslav Lichvar [Fri, 13 May 2016 10:28:32 +0000 (12:28 +0200)] 
make_release: update for changes in documentation

10 years agomakefile: remove config.h and config.log in distclean
Miroslav Lichvar [Fri, 13 May 2016 10:27:51 +0000 (12:27 +0200)] 
makefile: remove config.h and config.log in distclean

10 years agoupdate copyright years
Miroslav Lichvar [Fri, 13 May 2016 11:29:10 +0000 (13:29 +0200)] 
update copyright years

10 years agodoc: update examples of configuration in isolated networks
Miroslav Lichvar [Thu, 12 May 2016 15:18:29 +0000 (17:18 +0200)] 
doc: update examples of configuration in isolated networks

10 years agodoc: fix typo in chronyc man page
Miroslav Lichvar [Thu, 12 May 2016 13:24:12 +0000 (15:24 +0200)] 
doc: fix typo in chronyc man page

10 years agodoc: update FAQ
Miroslav Lichvar [Thu, 12 May 2016 13:21:26 +0000 (15:21 +0200)] 
doc: update FAQ

10 years agontp: don't check for synchronization loop in special reference modes
Miroslav Lichvar [Thu, 12 May 2016 13:43:42 +0000 (15:43 +0200)] 
ntp: don't check for synchronization loop in special reference modes

If a special reference mode is enabled, always pass the test for
synchronization loop. This allows chronyd using the initstepslew
directive (or the -q/-Q option) to accept time from its own clients
after restart as is documented in the chrony.conf man page.

This was broken since update to NTPv4.

10 years agorefclock: avoid reallocation of refclock instances
Miroslav Lichvar [Wed, 11 May 2016 14:31:51 +0000 (16:31 +0200)] 
refclock: avoid reallocation of refclock instances

Change the array with refclock instances to store just pointers and
avoid reallocation of the instances. This fixes a bug with the SOCK
refclock, which uses the pointer to the instance in a file handler and
which was invalid when the instance was reallocated (after adding
another refclock).

The bug is from commit d92583ed330f4c1f5f29fc1fc7c01d2a19d12319.

10 years agosched: fix handling of signals after finalization
Miroslav Lichvar [Fri, 15 Apr 2016 12:49:03 +0000 (14:49 +0200)] 
sched: fix handling of signals after finalization

Don't require the scheduler to be initialized in SCH_QuitProgram().
This fixes a crash when a signal is received between scheduler
finalization and chronyd exit.

10 years agosources: consider only reachable orphans for selection
Miroslav Lichvar [Wed, 13 Apr 2016 09:43:36 +0000 (11:43 +0200)] 
sources: consider only reachable orphans for selection

Ignore orphan sources that are unreachable (but still have usable stats)
to have a quick and consistent source selection between orphans.

This also fixes the "Unknown local refid in orphan mode" error appearing
when a selected orphan source is removed, as the source is marked as
unreachable and the selection runs with disabled NTP instance before the
source instance is actually removed.

10 years agodoc: fix typos in man pages
Miroslav Lichvar [Tue, 12 Apr 2016 10:31:04 +0000 (12:31 +0200)] 
doc: fix typos in man pages

10 years agodoc: improve answer in FAQ for error 501 Not authorised
Miroslav Lichvar [Tue, 12 Apr 2016 10:27:31 +0000 (12:27 +0200)] 
doc: improve answer in FAQ for error 501 Not authorised

10 years agodoc: use https in links to chrony website
Miroslav Lichvar [Tue, 12 Apr 2016 10:01:46 +0000 (12:01 +0200)] 
doc: use https in links to chrony website

10 years agoclient: initialize variables in new local command
Miroslav Lichvar [Mon, 11 Apr 2016 06:28:45 +0000 (08:28 +0200)] 
client: initialize variables in new local command

10 years agoreference: rework activation of local reference
Miroslav Lichvar [Fri, 8 Apr 2016 13:50:27 +0000 (15:50 +0200)] 
reference: rework activation of local reference

Instead of using a timer for switching the reference to the
unsynchronised state (which activates the local reference), check
if it should be active when returning the reference parameters.

10 years agoreference: return real sync status in REF_GetReferenceParams()
Miroslav Lichvar [Fri, 8 Apr 2016 14:10:02 +0000 (16:10 +0200)] 
reference: return real sync status in REF_GetReferenceParams()

If local reference is active, return normal leap, but unsynchronised
status. Update the callers of the function to work with the leap
directly and not change their behaviour.

REF_IsLocalActive() is no longer needed.

10 years agoreference: report same values in tracking command as in NTP
Miroslav Lichvar [Thu, 7 Apr 2016 15:09:01 +0000 (17:09 +0200)] 
reference: report same values in tracking command as in NTP

Use REF_GetReferenceParams() in the tracking command to simplify the
code and report the same values as what NTP clients of the server see.

When the local reference mode is active, this changes the leap status to
synchronised and reference time to one second behind current time. When
not synchronised, the root delay and root dispersion are now 1 second.

10 years agostubs: add NSR_GetLocalRefid()
Miroslav Lichvar [Fri, 8 Apr 2016 10:41:13 +0000 (12:41 +0200)] 
stubs: add NSR_GetLocalRefid()

10 years agocmdmon: extend local command to match local directive
Miroslav Lichvar [Thu, 7 Apr 2016 14:33:23 +0000 (16:33 +0200)] 
cmdmon: extend local command to match local directive

10 years agoreference: clamp local stratum set from cmdmon
Miroslav Lichvar [Fri, 8 Apr 2016 10:34:48 +0000 (12:34 +0200)] 
reference: clamp local stratum set from cmdmon

10 years agocmdparse: check if stratum in local directive is valid
Miroslav Lichvar [Wed, 6 Apr 2016 14:38:14 +0000 (16:38 +0200)] 
cmdparse: check if stratum in local directive is valid

10 years agocmdmon: remove obsolete definition
Miroslav Lichvar [Wed, 6 Apr 2016 13:56:12 +0000 (15:56 +0200)] 
cmdmon: remove obsolete definition

10 years agontp: ignore order of resolved addresses when replacing tentative source
Miroslav Lichvar [Tue, 5 Apr 2016 15:15:26 +0000 (17:15 +0200)] 
ntp: ignore order of resolved addresses when replacing tentative source

If the replaced source never had a valid reply (e.g. because it was a
bad replacement), ignore the order of addresses from the resolver to not
get stuck to a pair of addresses if the order doesn't change, or a group
of IPv4/IPv6 addresses if the resolver prefers inaccessible IP family.

10 years agontp: mark all new sources and replacements as tentative
Miroslav Lichvar [Mon, 4 Apr 2016 16:09:34 +0000 (18:09 +0200)] 
ntp: mark all new sources and replacements as tentative

10 years agodoc: update description of local directive
Miroslav Lichvar [Fri, 1 Apr 2016 16:42:43 +0000 (18:42 +0200)] 
doc: update description of local directive

10 years agontp: don't check reference timestamp in received packets
Miroslav Lichvar [Fri, 1 Apr 2016 12:24:04 +0000 (14:24 +0200)] 
ntp: don't check reference timestamp in received packets

When ntpd as an NTP server has active orphan mode, it doesn't update
its reference time and the reference timestamp may fail the NTP test
3 and 7. (https://bugs.ntp.org/show_bug.cgi?id=1098)

Remove both checks of the timestamp to allow chronyd to operate as
a client of ntpd server in the orphan mode. When ntpd is fixed and
old versions are no longer used, this may be reverted.

10 years agosources: log error when local refid is unknown in orphan mode
Miroslav Lichvar [Fri, 1 Apr 2016 07:37:49 +0000 (09:37 +0200)] 
sources: log error when local refid is unknown in orphan mode

10 years agotest: add 121-orphan
Miroslav Lichvar [Thu, 31 Mar 2016 13:57:56 +0000 (15:57 +0200)] 
test: add 121-orphan

10 years agosources: add support for orphan sources
Miroslav Lichvar [Wed, 30 Mar 2016 15:39:49 +0000 (17:39 +0200)] 
sources: add support for orphan sources

When the local reference is configured with the orphan option, NTP
sources that have stratum equal to the configured local stratum are
considered to be orphans (i.e. serving local time while not being
synchronised with real time) and are excluded from the normal source
selection. Sources with stratum larger than the local stratum are
considered to be directly on indirectly synchronised to an orphan and
are always ignored.

If no selectable source is available and all orphan sources have
reference IDs larger than the local ID, no source will be selected and
the local reference mode will be activated at some point, i.e. this host
will become an orphan. Otherwise, the orphan source with the smallest
reference ID will be selected. This ensures a group of servers polling
each other (with the same orphan configuration) which have no external
source can settle down to a state where only one server is serving its
local unsychronised time and others are synchronised to it.

10 years agoreference: add orphan mode to local reference
Miroslav Lichvar [Wed, 30 Mar 2016 15:39:14 +0000 (17:39 +0200)] 
reference: add orphan mode to local reference

Add orphan option to the local directive. It will enable an orphan mode
compatible with ntpd.

10 years agoreference: activate local reference with large root distance
Miroslav Lichvar [Wed, 30 Mar 2016 15:12:12 +0000 (17:12 +0200)] 
reference: activate local reference with large root distance

Since the update to NTPv4, when the clock is in the synchronised state
and the clock updates stop (e.g. sources become unreachable), it doesn't
switch to the unsynchronised state and the local reference is never
activate. This can be a problem for clients that rely on the server to
always have root distance below some value (e.g. chronyd's maxdistance).

Add a timer that will activate the local reference when the root
distance reaches a specified threshold. It can be configured with the
distance option in the local directive (by default 1.0 second).

10 years agoconf: rework local directive to have default stratum
Miroslav Lichvar [Wed, 30 Mar 2016 13:58:45 +0000 (15:58 +0200)] 
conf: rework local directive to have default stratum

Allow the local directive to be specified without the stratum field.
It's an option now, with default value 10. Also, move the parsing code
to cmdparse.c to make it available to the client.

10 years agontp: add function to get local reference ID
Miroslav Lichvar [Wed, 30 Mar 2016 09:02:04 +0000 (11:02 +0200)] 
ntp: add function to get local reference ID

When a valid NTP reply is received, save the local address (e.g. from
IP_PKTINFO), so the reference ID which would the source use for this
host can be calculated when needed.

10 years agosys_linux: include <termios.h> for TCGETS
Miroslav Lichvar [Tue, 29 Mar 2016 08:06:21 +0000 (10:06 +0200)] 
sys_linux: include <termios.h> for TCGETS

10 years agolocal: make maximum frequency offset configurable
Miroslav Lichvar [Tue, 22 Mar 2016 16:07:46 +0000 (17:07 +0100)] 
local: make maximum frequency offset configurable

Add maxdrift directive to set the maximum assumed drift of the clock,
which sets the maximum frequency offset chronyd is allowed to use to
to correct the drift.

10 years agosources: try to replace NTP sources with bad distance
Miroslav Lichvar [Tue, 22 Mar 2016 16:01:38 +0000 (17:01 +0100)] 
sources: try to replace NTP sources with bad distance

Similarly to unreachable sources and falsetickers, try to replace
sources with distance larger than the limit set by the maxdistance
directive with a newly resolved address of the hostname.

10 years agoclient: ignore -v option in csv mode
Miroslav Lichvar [Fri, 18 Mar 2016 13:28:53 +0000 (14:28 +0100)] 
client: ignore -v option in csv mode

10 years agoutil: fix UTI_FloatNetworkToHost() with very small exponents
Miroslav Lichvar [Thu, 17 Mar 2016 13:28:45 +0000 (14:28 +0100)] 
util: fix UTI_FloatNetworkToHost() with very small exponents

Fix conversion of floating point numbers from the cmdmon format with
very small exponents, as for instance could be in the smoothing report
when the smoothing process ends.

This was broken in commit 8e71a46173afe01e11620980a1c7c028d7fd048f.

10 years agoclient: add CSV output mode
Miroslav Lichvar [Wed, 16 Mar 2016 14:50:47 +0000 (15:50 +0100)] 
client: add CSV output mode

Add a new option (-c) to chronyc to enable printing of reports in a
column-separated values (CSV) format. IP addresses will not be resolved
to hostnames, time will be printed as number of seconds since the epoch
and values in seconds will not be converted to other units.

10 years agoclient: rework printing of reports
Miroslav Lichvar [Wed, 16 Mar 2016 11:05:42 +0000 (12:05 +0100)] 
client: rework printing of reports

Add a new printf-like function to allow printing of all fields at once
and rework all commands which print a report to use it. Add functions
for printing of headers and information fields, and formatting of IP
addresses and reference IDs.

10 years agoutil: randomize hashing of IP addresses
Miroslav Lichvar [Mon, 14 Mar 2016 17:06:56 +0000 (18:06 +0100)] 
util: randomize hashing of IP addresses

Include a random (constant) value in the hash in UTI_IPToHash() to
randomize the order in which NTP sources are stored in the hash table
and polled on start. This change also randomizes the order of clientlog
records.

10 years agotest: make 105-ntpauth more reliable
Miroslav Lichvar [Mon, 14 Mar 2016 16:42:49 +0000 (17:42 +0100)] 
test: make 105-ntpauth more reliable

10 years agomakefile: add distclean target to test/unit/Makefile
Miroslav Lichvar [Mon, 14 Mar 2016 14:51:53 +0000 (15:51 +0100)] 
makefile: add distclean target to test/unit/Makefile

10 years agomakefile: remove Makefile in doc/Makefile on distclean
Miroslav Lichvar [Mon, 14 Mar 2016 14:50:59 +0000 (15:50 +0100)] 
makefile: remove Makefile in doc/Makefile on distclean

10 years agontp: improve error messages for socket options
Miroslav Lichvar [Mon, 14 Mar 2016 14:41:05 +0000 (15:41 +0100)] 
ntp: improve error messages for socket options

10 years agocmdmon: extend initialization checks
Miroslav Lichvar [Mon, 14 Mar 2016 14:31:11 +0000 (15:31 +0100)] 
cmdmon: extend initialization checks

Move the message size checks to a separate function and check also
header size in the command request and reply to catch incompatible
changes.

10 years agorewrite assertions with very long messages
Miroslav Lichvar [Mon, 14 Mar 2016 14:15:51 +0000 (15:15 +0100)] 
rewrite assertions with very long messages

10 years agoclient: add reselectdist to help text
Miroslav Lichvar [Fri, 11 Mar 2016 14:17:39 +0000 (15:17 +0100)] 
client: add reselectdist to help text

10 years agogit: update .gitignore
Miroslav Lichvar [Fri, 11 Mar 2016 11:46:06 +0000 (12:46 +0100)] 
git: update .gitignore

10 years agodoc: convert manual from Texinfo to AsciiDoc
Miroslav Lichvar [Mon, 7 Mar 2016 09:43:52 +0000 (10:43 +0100)] 
doc: convert manual from Texinfo to AsciiDoc

Split and convert the manual into four AsciiDoc documents, a document
about installation and three documents in the manpage type for
chrony.conf, chronyd and chronyc. The minimal man pages that were
maintained separately from the manual are replaced by full man pages
generated from AsciiDoc. Info files will no longer be provided.

Some parts of the manual are rewritten, updated or trimmed. The
introduction chapter is partially merged with README. The chapter about
typical operating scenarios is included in the chrony.conf man page.

10 years agodoc: update installation instructions 2.3
Miroslav Lichvar [Tue, 16 Feb 2016 13:22:58 +0000 (14:22 +0100)] 
doc: update installation instructions

10 years agodoc: improve description of trust option
Miroslav Lichvar [Tue, 16 Feb 2016 11:45:07 +0000 (12:45 +0100)] 
doc: improve description of trust option

10 years agotest/unit: add sources unit test
Miroslav Lichvar [Mon, 15 Feb 2016 15:08:15 +0000 (16:08 +0100)] 
test/unit: add sources unit test

10 years agotest/unit: include microseconds in default random seed
Miroslav Lichvar [Mon, 15 Feb 2016 15:05:43 +0000 (16:05 +0100)] 
test/unit: include microseconds in default random seed