Description
OpenNTPD is a service that can be used to synchronize the system clock to the time servers using the NTP .
OpenNTPD is a part the OpenBSD base system. It was ported to others OSes, as Devuan.
Installation
With the apt
tool: apt install openntpd
Configuration
- The file config is:
/etc/opennptd/ntpd.conf
By default, it runs without no needed modification.
File: /etc/opennptd/ntpd.conf
|
|
Explanations
About options:
server
: to target on time server, in particular.servers
: to targer a pool of time servers - prefer thissensor
: to use local timedelta sensor
Utilisation
Checks
To check the file config, use the option -n
, as-is:
# openntpd -n
configuration OK
If not good, you need to review the file config.
ntpctl
is the tool to control the time informations.
- the option
-s all
- or-sa
- is to display availables informations.
Code: shell
Service
The service name is openntpd, to manage with the service
.
service openntpd command
command
is one of possibles actions on a service, asstart
,stop
,restart
.
Troubleshooting
It can happen at startup that there is a time lag. Using the option -s
solve:
Code: shell
Constraint
It seems the constraint option is not available!
constraint
ensures that time queries are made on the
protocol HTTPS
,
via TLS
.peer not valid
You have this message:
Code: shell
Wait a little for the ntp queries to be returned.
Normally at the next query, this should no longer be the case.
Otherwise, check that the NTP servers registered in the file config are well written, reachable and functional.
Documentation
The NTP protocol is defined in:
RFC 1305
RFC 5905
Manpages
Please, read the manpages: