1 @node update-leap Invocation
2 @section Invoking update-leap
4 @cindex leap-seconds file manager/updater
7 # EDIT THIS FILE WITH CAUTION (invoke-update-leap.texi)
9 # It has been AutoGen-ed January 7, 2016 at 11:27:05 PM by AutoGen 5.18.5
10 # From the definitions update-leap-opts.def
11 # and the template file agtexi-cmd.tpl
17 will validate the file currently on the local system
18 and if necessary, updates leap-second definition file.
20 Ordinarily, the file is found using the "leapfile" directive in
22 However, an alternate location can be specified on the command line.
24 If the file does not exist, is not valid, has expired, or is expiring soon,
25 a new copy will be downloaded. If the new copy validates, it is installed and
26 NTP is (optionally) restarted.
28 If the current file is acceptable, no download or restart occurs.
30 -c can also be used to invoke another script to perform administrative
31 functions, e.g. to copy the file to other local systems.
33 This can be run as a cron job. As the file is rarely updated, and leap
34 seconds are announced at least one month in advance (usually longer), it
35 need not be run more frequently than about once every three weeks.
37 For cron-friendly behavior, define CRONJOB=1 in the crontab.
39 This script depends on$REQUIREDCMDS
41 This section was generated by @strong{AutoGen},
42 using the @code{agtexi-cmd} template and the option descriptions for the @code{update-leap} program.
45 * update-leap usage:: update-leap help/usage (@option{--help})
46 * update-leap source-url:: source-url option (-s)
47 * update-leap ipv4:: ipv4 option (-4)
48 * update-leap destination:: destination option (-d)
49 * update-leap expiration:: expiration option (-e)
50 * update-leap ntp-conf-file:: ntp-conf-file option (-f)
51 * update-leap force-update:: force-update option (-F)
52 * update-leap exit status:: exit status
53 * update-leap Usage:: Usage
54 * update-leap Authors:: Authors
57 @node update-leap usage
58 @subsection update-leap help/usage (@option{--help})
59 @cindex update-leap help
61 This is the automatically generated usage text for update-leap.
63 The text printed is the same whether selected with the @code{help} option
64 (@option{--help}) or the @code{more-help} option (@option{--more-help}). @code{more-help} will print
65 the usage text by passing it through a pager program.
66 @code{more-help} is disabled on platforms without a working
67 @code{fork(2)} function. The @code{PAGER} environment variable is
68 used to select the program, defaulting to @file{more}. Both will exit
69 with a status code of 0.
74 Usage: $0 [options] [leapfile]
76 Verifies and if necessary, updates leap-second definition file
78 All arguments are optional: Default (or current value) shown: -s
79 Specify the URL of the master copy to download $LEAPSRC -d Specify
80 the filename on the local system $LEAPFILE -e Specify how long (in
81 days) before expiration the file is to be refreshed. Note that
82 larger values imply more frequent refreshes. "$PREFETCH" -f Specify
83 location of ntp.conf (used to make sure leapfile directive is
84 present and to default leapfile) $NTPCONF -F Force update even if
85 current file is OK and not close to expiring. -r Specify number of
86 times to retry on get failure $MAXTRIES -i Specify number of minutes
87 between retries $INTERVAL -l Use syslog for output (Implied if
88 CRONJOB is set) -L Don't use syslog for output -P Specify the syslog
89 facility for logging $LOGFAC -t Name of temporary file used in
90 validation $TMPFILE -q Only report errors to stdout -v Verbose
93 The following options are not (yet) implemented in the perl version:
94 -4 Use only IPv4 -6 Use only IPv6 -c Command to restart NTP after
95 installing a new file <none> - ntpd checks file daily -p 4|6 Prefer
96 IPv4 or IPv6 (as specified) addresses, but use either -z Specify
97 path for utilities $PATHLIST -Z Only use system path
99 $0 will validate the file currently on the local system
101 Ordinarily, the file is found using the "leapfile" directive in
102 $NTPCONF. However, an alternate location can be specified on the
105 If the file does not exist, is not valid, has expired, or is
106 expiring soon, a new copy will be downloaded. If the new copy
107 validates, it is installed and NTP is (optionally) restarted.
109 If the current file is acceptable, no download or restart occurs.
111 -c can also be used to invoke another script to perform
112 administrative functions, e.g. to copy the file to other local
115 This can be run as a cron job. As the file is rarely updated, and
116 leap seconds are announced at least one month in advance (usually
117 longer), it need not be run more frequently than about once every
120 For cron-friendly behavior, define CRONJOB=1 in the crontab.
126 @node update-leap source-url
127 @subsection source-url option (-s)
128 @cindex update-leap-source-url
130 This is the ``the url of the master copy of the leapseconds file'' option.
131 This option takes a string argument.
132 Specify the URL of the master copy to download
134 @node update-leap ipv4
135 @subsection ipv4 option (-4)
136 @cindex update-leap-ipv4
138 This is the ``use only ipv4 addresses for dns name resolution'' option.
141 This option has some usage constraints. It:
144 must not appear in combination with any of the following options:
148 Force DNS resolution of following host names on the command line
149 to the IPv4 namespace.
155 flags-cant = ipv4, prefer;
157 descrip = "Use only IPv6 addresses for DNS name resolution";
159 Force DNS resolution of following host names on the command line
160 to the IPv6 namespace.
166 flags-cant = ipv4, ipv6;
170 descrip = 'Prefer IPv4 or IPv6 (as specified) addresses, but use either';
172 Prefer IPv4 or IPv6 (as specified) addresses, but use either.
173 @node update-leap destination
174 @subsection destination option (-d)
175 @cindex update-leap-destination
177 This is the ``filename on the local system'' option.
178 This option takes a string argument @file{float}.
179 The name to use to store the leapfile on the local system.
181 @node update-leap expiration
182 @subsection expiration option (-e)
183 @cindex update-leap-expiration
185 This is the ``refresh the leapfile this long before it expires'' option.
186 This option takes a string argument.
187 Specify how long before expiration the file is to be refreshed
188 Units are required, e.g. "-e 60 days" Note that larger values
189 imply more frequent refreshes.
191 @node update-leap ntp-conf-file
192 @subsection ntp-conf-file option (-f)
193 @cindex update-leap-ntp-conf-file
195 This is the ``location of the ntp.conf file'' option.
196 This option takes a string argument.
197 Specify location of ntp.conf (used to make sure leapfile directive is
198 present and to default leapfile)
200 @node update-leap force-update
201 @subsection force-update option (-F)
202 @cindex update-leap-force-update
204 This is the ``force update of the leapfile'' option.
205 Force update even if current file is OK and not close to expiring.
206 @node update-leap exit status
207 @subsection update-leap exit status
209 One of the following exit values will be returned:
211 @item 0 (EXIT_SUCCESS)
212 Successful program execution.
213 @item 1 (EXIT_FAILURE)
214 The operation failed or the command syntax was not valid.
216 @node update-leap Usage
217 @subsection update-leap Usage
218 @node update-leap Authors
219 @subsection update-leap Authors