table of contents
other versions
- wheezy 1:4.2.6.p5+dfsg-2+deb7u6
- jessie 1:4.2.6.p5+dfsg-7+deb8u2
- testing 1:4.2.8p10+dfsg-3
- unstable 1:4.2.8p10+dfsg-3
- experimental 1:4.2.8p10+dfsg-3+exp4
SNTP(1) | Programmer's Manual | SNTP(1) |
NAME¶
sntp - standard Simple Network Time Protocol programSYNOPSIS¶
sntp [-flag [value]]... [--opt-name [[=| ] value]]...[ hostname-or-IP ...]
DESCRIPTION¶
This manual page briefly documents the sntp command. sntp can be used as a SNTP client to query a NTP or SNTP server and either display the time or set the local system's time (given suitable privilege). It can be run as an interactive command or in a cron job.OPTIONS¶
- -4, --ipv4
- Force IPv4 DNS name resolution. This option must not appear
in combination with any of the following options: ipv6.
- -6, --ipv6
- Force IPv6 DNS name resolution. This option must not appear
in combination with any of the following options: ipv4.
- -d, --normalverbose
- Normal verbose.
- -K file-name, --kod=file-name
- KoD history filename.
- -p, --syslog
- Logging with syslog. This option must not appear in
combination with any of the following options: logfile.
- -l file-name, --logfile=file-name
- Log to specified logfile. This option must not appear in
combination with any of the following options: syslog.
- -s, --settod
- Set (step) the time with settimeofday(). This option must
not appear in combination with any of the following options: adjtime.
- -j, --adjtime
- Set (slew) the time with adjtime(). This option must not
appear in combination with any of the following options: settod.
- -b broadcast-address, --broadcast=broadcast-address
- Use broadcasts to the address specified for
synchronisation.
- -t seconds, --timeout=seconds
- Specify the number of seconds to wait for broadcasts. This
option takes an integer number as its argument. The default seconds
for this option is:
68
- -a auth-keynumber, --authentication=auth-keynumber
- Enable authentication with the key auth-keynumber. This
option takes an integer number as its argument.
- -k file-name, --keyfile=file-name
- Specify a keyfile. SNTP will look in this file for the key
specified with -a.
- -?, --help
- Display extended usage information and exit.
- -!, --more-help
- Extended usage information passed thru pager.
- -> [rcfile], --save-opts[=rcfile]
- Save the option state to rcfile. The default is the last configuration file listed in the OPTION PRESETS section, below.
- -< rcfile, --load-opts=rcfile, --no-load-opts
- Load options from rcfile. The no-load-opts form will disable the loading of earlier RC/INI files. --no-load-opts is handled early, out of order.
- - [{v|c|n}], --version[={v|c|n}]
- Output version of program and exit. The default mode is `v', a simple version. The `c' mode will print copyright information and `n' will print the full copyright notice.
OPTION PRESETS¶
Any option that is not marked as not presettable may be preset by loading values from configuration ("RC" or ".INI") file(s) and values from environment variables named:SNTP_<option-name> or SNTPThe environmental presets take precedence (are processed later than) the configuration files. The homerc files are "$HOME", and " .". If any of these are directories, then the file .ntprc is searched for within those directories.
USAGE¶
The simplest use of this program is as an unprivileged command to check the current time and error in the local clock. For example:- sntp ntpserver.somewhere
- sntp -a ntpserver.somewhere
RETURN VALUE¶
The program returns a zero exit status for success, and a non-zero one otherwise.BUGS¶
Please report bugs to http://bugs.ntp.org .AUTHOR¶
David L. Mills and/or otherssee html/copyright.htmlThis manual page was AutoGen-erated from the sntp option definitions.
2011-12-24 | ( 4.2.6p5) |