source: basicnet/netprogs/ntp.xml@ c267b261

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 6.2 6.2.0 6.2.0-rc1 6.2.0-rc2 6.3 6.3-rc1 6.3-rc2 6.3-rc3 7.10 7.4 7.5 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since c267b261 was bca6dfb6, checked in by Bruce Dubbs <bdubbs@…>, 18 years ago

Typos in ntp config

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@5947 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 10.0 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3 "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY ntp-download-http "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-&ntp-version;.tar.gz">
8 <!ENTITY ntp-download-ftp "ftp://ftp.udel.edu/pub/ntp/ntp4/ntp-&ntp-version;.tar.gz">
9 <!ENTITY ntp-md5sum "0f8fabe87cf54f409b57c6283f0c0c3d">
10 <!ENTITY ntp-size "2.4 MB">
11 <!ENTITY ntp-buildsize "27 MB">
12 <!ENTITY ntp-time "0.53 SBU">
13]>
14
15<sect1 id="ntp" xreflabel="NTP-&ntp-version;">
16 <?dbhtml filename="ntp.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 <keywordset>
22 <keyword role="package">ntp-&ntp-version;.tar</keyword>
23 <keyword role="ftpdir">ntp</keyword>
24 </keywordset>
25 </sect1info>
26
27 <title>NTP-&ntp-version;</title>
28
29 <indexterm zone="ntp">
30 <primary sortas="a-NTP">NTP</primary>
31 </indexterm>
32
33 <sect2 role="package">
34 <title>Introduction to NTP</title>
35
36 <para>The <application>NTP</application> package contains a
37 client and server to keep the time synchronized between various computers over
38 a network. This package is the official reference implementation of the
39 NTP protocol.</para>
40
41 <bridgehead renderas="sect3">Package Information</bridgehead>
42 <itemizedlist spacing="compact">
43 <listitem>
44 <para>Download (HTTP): <ulink url="&ntp-download-http;"/></para>
45 </listitem>
46 <listitem>
47 <para>Download (FTP): <ulink url="&ntp-download-ftp;"/></para>
48 </listitem>
49 <listitem>
50 <para>Download MD5 sum: &ntp-md5sum;</para>
51 </listitem>
52 <listitem>
53 <para>Download size: &ntp-size;</para>
54 </listitem>
55 <listitem>
56 <para>Estimated disk space required: &ntp-buildsize;</para>
57 </listitem>
58 <listitem>
59 <para>Estimated build time: &ntp-time;</para>
60 </listitem>
61 </itemizedlist>
62
63 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
64 <itemizedlist spacing='compact'>
65 <listitem>
66 <para>Required patch: <ulink
67 url="&patch-root;/ntp-&ntp-version;-gcc4-1.patch"/></para>
68 </listitem>
69 </itemizedlist>
70
71 <bridgehead renderas="sect3">NTP Dependencies</bridgehead>
72
73 <bridgehead renderas="sect4">Optional</bridgehead>
74 <para role="optional"><xref linkend="openssl"/></para>
75
76 <para condition="html" role="usernotes">User Notes:
77 <ulink url="&blfs-wiki;/ntp"/></para>
78
79 </sect2>
80
81 <sect2 role="installation">
82 <title>Installation of NTP</title>
83
84 <para>Install <application>NTP</application> by running
85 the following commands:</para>
86
87<screen><userinput>patch -Np1 -i ../ntp-&ntp-version;-gcc4-1.patch &amp;&amp;
88./configure --prefix=/usr --bindir=/usr/sbin \
89 --sysconfdir=/etc &amp;&amp;
90make</userinput></screen>
91
92 <para>To test the results, issue: <command>make check</command>.</para>
93
94 <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
95
96<screen role="root"><userinput>make install &amp;&amp;
97install -v -m755 -d /usr/share/doc/ntp-&ntp-version; &amp;&amp;
98cp -v -R html /usr/share/doc/ntp-&ntp-version;/</userinput></screen>
99
100 </sect2>
101
102 <sect2 role="configuration">
103 <title>Configuring NTP</title>
104
105 <sect3 id="ntp-config">
106 <title>Config Files</title>
107
108 <para><filename>/etc/ntp.conf</filename></para>
109
110 <indexterm zone="ntp ntp-config">
111 <primary sortas="e-etc-ntp.conf">/etc/ntp.conf</primary>
112 </indexterm>
113
114 </sect3>
115
116 <sect3>
117 <title>Configuration Information</title>
118
119 <para>The following configuration file defines various NTP servers with
120 open access from different continents. It also creates a drift file where
121 <command>ntpd</command> stores the frequency offset. Since the
122 documentation included with the package is sparse, visit the NTP website
123 at <ulink url="http://www.ntp.org/"/> and <ulink
124 url="http://www.pool.ntp.org/"/> for more information.</para>
125
126<screen role="root"><userinput>cat &gt; /etc/ntp.conf &lt;&lt; "EOF"
127<literal># Africa
128server tock.nml.csir.co.za
129
130# Asia
131server 0.asia.pool.ntp.org
132
133# Australia
134server 0.oceania.pool.ntp.org
135
136# Europe
137server 0.europe.pool.ntp.org
138
139# North America
140server 0.north-america.pool.ntp.org
141
142# South America
143server 2.south-america.pool.ntp.org
144
145driftfile /var/cache/ntp.drift</literal>
146EOF</userinput></screen>
147
148 </sect3>
149
150 <sect3 id="ntp-init">
151 <title>Synchronizing the Time</title>
152
153 <para>There are two options. Option one is to run <command>ntpd</command>
154 continuously and allow it to synchronize the time in a gradual manner. The
155 other option is to run <command>ntpd</command> periodically (using cron)
156 and update the time each time <command>ntpd</command> is scheduled.</para>
157
158 <para>If you choose Option one, then install the
159 <filename>/etc/rc.d/init.d/ntp</filename>
160 init script included in the
161 <xref linkend="bootscripts"/> package.</para>
162
163 <indexterm zone="ntp ntp-init">
164 <primary sortas="f-ntp">ntp</primary>
165 </indexterm>
166
167<screen role="root"><userinput>make install-ntp</userinput></screen>
168
169 <para>If you prefer to run <command>ntpd</command> periodically, add the
170 following command to <systemitem class="username">root</systemitem>'s
171 <filename>crontab</filename>:</para>
172
173<screen><literal>ntpd -q</literal></screen>
174
175 <para>Execute the following command if you would like to set the
176 hardware clock to the current system time at shutdown and reboot:</para>
177
178<screen role="root"><userinput>ln -v -sf ../init.d/setclock /etc/rc.d/rc0.d/K46setclock &amp;&amp;
179ln -v -sf ../init.d/setclock /etc/rc.d/rc6.d/K46setclock</userinput></screen>
180
181 <para>The other way around is already set up by LFS.</para>
182
183 </sect3>
184
185 </sect2>
186
187 <sect2 role="content">
188 <title>Contents</title>
189
190 <segmentedlist>
191 <segtitle>Installed Programs</segtitle>
192 <segtitle>Installed Libraries</segtitle>
193 <segtitle>Installed Directory</segtitle>
194
195 <seglistitem>
196 <seg>ntp-keygen, ntp-wait, ntpd, ntpdate, ntpdc, ntpq,
197 ntptime, ntptrace, and tickadj</seg>
198 <seg>None</seg>
199 <seg>/usr/share/doc/ntp-&ntp-version;</seg>
200 </seglistitem>
201 </segmentedlist>
202
203 <variablelist>
204 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
205 <?dbfo list-presentation="list"?>
206 <?dbhtml list-presentation="table"?>
207
208 <varlistentry id="ntp-keygen">
209 <term><command>ntp-keygen</command></term>
210 <listitem>
211 <para>generates cryptographic data files used by the NTPv4 authentication
212 and identification schemes.</para>
213 <indexterm zone="ntp ntp-keygen">
214 <primary sortas="b-ntp-keygen">ntp-keygen</primary>
215 </indexterm>
216 </listitem>
217 </varlistentry>
218
219 <varlistentry id="ntp-wait">
220 <term><command>ntp-wait</command></term>
221 <listitem>
222 <para>is useful at boot time, to delay the boot sequence until
223 <command>ntpd</command> has set the time.</para>
224 <indexterm zone="ntp ntp-wait">
225 <primary sortas="b-ntp-wait">ntp-wait</primary>
226 </indexterm>
227 </listitem>
228 </varlistentry>
229
230 <varlistentry id="ntpd">
231 <term><command>ntpd</command></term>
232 <listitem>
233 <para>is a NTP daemon that runs in the background and keeps
234 the date and time synchronized based on response from configured
235 NTP servers. It also functions as a NTP server.</para>
236 <indexterm zone="ntp ntpd">
237 <primary sortas="b-ntpd">ntpd</primary>
238 </indexterm>
239 </listitem>
240 </varlistentry>
241
242 <varlistentry id="ntpdate">
243 <term><command>ntpdate</command></term>
244 <listitem>
245 <para>is a client program that sets the date and time based on
246 the response from an NTP server. This command is deprecated.</para>
247 <indexterm zone="ntp ntpdate">
248 <primary sortas="b-ntpdate">ntpdate</primary>
249 </indexterm>
250 </listitem>
251 </varlistentry>
252
253 <varlistentry id="ntpdc">
254 <term><command>ntpdc</command></term>
255 <listitem>
256 <para>is used to query the NTP daemon about its current state
257 and to request changes in that state.</para>
258 <indexterm zone="ntp ntpdc">
259 <primary sortas="b-ntpdc">ntpdc</primary>
260 </indexterm>
261 </listitem>
262 </varlistentry>
263
264 <varlistentry id="ntpq">
265 <term><command>ntpq</command></term>
266 <listitem>
267 <para>is an utility program used to monitor <command>ntpd</command>
268 operations and determine performance.</para>
269 <indexterm zone="ntp ntpq">
270 <primary sortas="b-ntpq">ntpq</primary>
271 </indexterm>
272 </listitem>
273 </varlistentry>
274
275 <varlistentry id="ntptime">
276 <term><command>ntptime</command></term>
277 <listitem>
278 <para>reads and displays time-related kernel variables.</para>
279 <indexterm zone="ntp ntptime">
280 <primary sortas="b-ntptime">ntptime</primary>
281 </indexterm>
282 </listitem>
283 </varlistentry>
284
285 <varlistentry id="ntptrace">
286 <term><command>ntptrace</command></term>
287 <listitem>
288 <para>traces a chain of NTP servers back to the primary source.</para>
289 <indexterm zone="ntp ntptrace">
290 <primary sortas="b-ntptrace">ntptrace</primary>
291 </indexterm>
292 </listitem>
293 </varlistentry>
294
295 <varlistentry id="tickadj">
296 <term><command>tickadj</command></term>
297 <listitem>
298 <para>reads, and optionally modifies, several timekeeping-related
299 variables in older kernels that do not have support for precision
300 timekeeping.</para>
301 <indexterm zone="ntp tickadj">
302 <primary sortas="b-tickadj">tickadj</primary>
303 </indexterm>
304 </listitem>
305 </varlistentry>
306
307 </variablelist>
308
309 </sect2>
310
311</sect1>
Note: See TracBrowser for help on using the repository browser.