| 1 |
<?xml version='1.0'?> <!--*-nxml-*--> |
| 2 |
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" |
| 3 |
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd"> |
| 4 |
<!-- SPDX-License-Identifier: LGPL-2.1-or-later --> |
| 5 |
|
| 6 |
<refentry id="timesyncd.conf" conditional='ENABLE_TIMESYNCD' |
| 7 |
xmlns:xi="http://www.w3.org/2001/XInclude"> |
| 8 |
<refentryinfo> |
| 9 |
<title>timesyncd.conf</title> |
| 10 |
<productname>systemd</productname> |
| 11 |
</refentryinfo> |
| 12 |
|
| 13 |
<refmeta> |
| 14 |
<refentrytitle>timesyncd.conf</refentrytitle> |
| 15 |
<manvolnum>5</manvolnum> |
| 16 |
</refmeta> |
| 17 |
|
| 18 |
<refnamediv> |
| 19 |
<refname>timesyncd.conf</refname> |
| 20 |
<refname>timesyncd.conf.d</refname> |
| 21 |
<refpurpose>Network Time Synchronization configuration files</refpurpose> |
| 22 |
</refnamediv> |
| 23 |
|
| 24 |
<refsynopsisdiv> |
| 25 |
<para><simplelist> |
| 26 |
<member><filename>/etc/systemd/timesyncd.conf</filename></member> |
| 27 |
<member><filename>/run/systemd/timesyncd.conf</filename></member> |
| 28 |
<member><filename>/usr/local/lib/systemd/timesyncd.conf</filename></member> |
| 29 |
<member><filename>/usr/lib/systemd/timesyncd.conf</filename></member> |
| 30 |
<member><filename>/etc/systemd/timesyncd.conf.d/*.conf</filename></member> |
| 31 |
<member><filename>/run/systemd/timesyncd.conf.d/*.conf</filename></member> |
| 32 |
<member><filename>/usr/local/lib/systemd/timesyncd.conf.d/*.conf</filename></member> |
| 33 |
<member><filename>/usr/lib/systemd/timesyncd.conf.d/*.conf</filename></member> |
| 34 |
</simplelist></para> |
| 35 |
</refsynopsisdiv> |
| 36 |
|
| 37 |
<refsect1> |
| 38 |
<title>Description</title> |
| 39 |
|
| 40 |
<para>These configuration files control NTP network time synchronization. See |
| 41 |
<citerefentry><refentrytitle>systemd.syntax</refentrytitle><manvolnum>7</manvolnum></citerefentry> |
| 42 |
for a general description of the syntax.</para> |
| 43 |
</refsect1> |
| 44 |
|
| 45 |
<xi:include href="standard-conf.xml" xpointer="main-conf" /> |
| 46 |
|
| 47 |
<refsect1> |
| 48 |
<title>Options</title> |
| 49 |
|
| 50 |
<para>The following settings are configured in the [Time] section:</para> |
| 51 |
|
| 52 |
<variablelist class='network-directives'> |
| 53 |
|
| 54 |
<varlistentry> |
| 55 |
<term><varname>NTP=</varname></term> |
| 56 |
<listitem><para>A space-separated list of NTP server host names or IP addresses. During runtime this |
| 57 |
list is combined with any per-interface NTP servers acquired from |
| 58 |
<citerefentry><refentrytitle>systemd-networkd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. |
| 59 |
<command>systemd-timesyncd</command> will contact all configured system or per-interface servers in |
| 60 |
turn, until one responds. When the empty string is assigned, the list of NTP servers is reset, and |
| 61 |
all prior assignments will have no effect. This setting defaults to an empty list.</para> |
| 62 |
|
| 63 |
<xi:include href="version-info.xml" xpointer="v216"/></listitem> |
| 64 |
</varlistentry> |
| 65 |
|
| 66 |
<varlistentry> |
| 67 |
<term><varname>FallbackNTP=</varname></term> |
| 68 |
<listitem><para>A space-separated list of NTP server host names or IP addresses to be used as the |
| 69 |
fallback NTP servers. Any per-interface NTP servers obtained from |
| 70 |
<citerefentry><refentrytitle>systemd-networkd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry> |
| 71 |
take precedence over this setting, as do any servers set via <varname>NTP=</varname> above. This |
| 72 |
setting is hence only relevant if no other NTP server information is known. When the empty string is |
| 73 |
assigned, the list of NTP servers is reset, and all prior assignments will have no effect. If this |
| 74 |
option is not given, a compiled-in list of NTP servers is used.</para> |
| 75 |
|
| 76 |
<xi:include href="version-info.xml" xpointer="v216"/></listitem> |
| 77 |
</varlistentry> |
| 78 |
|
| 79 |
<varlistentry> |
| 80 |
<term><varname>RootDistanceMaxSec=</varname></term> |
| 81 |
<listitem><para>Maximum acceptable root distance, i.e. the maximum estimated time required for a |
| 82 |
packet to travel to the server we are connected to from the server with the reference clock. If |
| 83 |
the current server does not satisfy this limit, <command>systemd-timesyncd</command> will switch |
| 84 |
to a different server.</para> |
| 85 |
|
| 86 |
<para>Takes a time span value. The default unit is seconds, but other units may be specified, see |
| 87 |
<citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry>. |
| 88 |
Defaults to 5 seconds.</para> |
| 89 |
|
| 90 |
<xi:include href="version-info.xml" xpointer="v236"/></listitem> |
| 91 |
</varlistentry> |
| 92 |
|
| 93 |
<varlistentry> |
| 94 |
<term><varname>PollIntervalMinSec=</varname></term> |
| 95 |
<term><varname>PollIntervalMaxSec=</varname></term> |
| 96 |
<listitem><para>The minimum and maximum poll intervals for NTP messages. Polling starts at the |
| 97 |
minimum poll interval, and is adjusted within the specified limits in response to received packets. |
| 98 |
</para> |
| 99 |
|
| 100 |
<para>Each setting takes a time span value. The default unit is seconds, but other units may be |
| 101 |
specified, see |
| 102 |
<citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry>. |
| 103 |
<varname>PollIntervalMinSec=</varname> defaults to 32 seconds and must not be smaller than |
| 104 |
16 seconds. <varname>PollIntervalMaxSec=</varname> defaults to 34 min 8 s (2048 seconds) and must be |
| 105 |
larger than <varname>PollIntervalMinSec=</varname>.</para> |
| 106 |
|
| 107 |
<xi:include href="version-info.xml" xpointer="v236"/></listitem> |
| 108 |
</varlistentry> |
| 109 |
|
| 110 |
<varlistentry> |
| 111 |
<term><varname>ConnectionRetrySec=</varname></term> |
| 112 |
<listitem><para>Specifies the minimum delay before subsequent attempts to contact a new NTP server |
| 113 |
are made.</para> |
| 114 |
|
| 115 |
<para>Takes a time span value. The default unit is seconds, but other units may be specified, see |
| 116 |
<citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry>. |
| 117 |
Defaults to 30 seconds and must not be smaller than 1 second.</para> |
| 118 |
|
| 119 |
<xi:include href="version-info.xml" xpointer="v248"/></listitem> |
| 120 |
</varlistentry> |
| 121 |
|
| 122 |
<varlistentry> |
| 123 |
<term><varname>SaveIntervalSec=</varname></term> |
| 124 |
<listitem><para>The interval at which the current time is periodically saved to disk, in the absence |
| 125 |
of any recent synchronisation from an NTP server. This is especially useful for offline systems |
| 126 |
with no local RTC, as it will guarantee that the system clock remains roughly monotonic across |
| 127 |
reboots.</para> |
| 128 |
|
| 129 |
<para>Takes a time interval value. The default unit is seconds, but other units may be specified, see |
| 130 |
<citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry>. |
| 131 |
Defaults to 60 seconds.</para> |
| 132 |
|
| 133 |
<xi:include href="version-info.xml" xpointer="v250"/></listitem> |
| 134 |
</varlistentry> |
| 135 |
|
| 136 |
</variablelist> |
| 137 |
</refsect1> |
| 138 |
|
| 139 |
<refsect1> |
| 140 |
<title>See Also</title> |
| 141 |
<para><simplelist type="inline"> |
| 142 |
<member><citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry></member> |
| 143 |
<member><citerefentry><refentrytitle>systemd-timesyncd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry></member> |
| 144 |
<member><citerefentry><refentrytitle>systemd-networkd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry></member> |
| 145 |
</simplelist></para> |
| 146 |
</refsect1> |
| 147 |
|
| 148 |
</refentry> |