mirror of
https://github.com/canonical/ubuntu-server-documentation.git
synced 2025-07-28 06:40:40 +00:00
e:networking: Update timesync defaults
This commit is contained in:
@ -31,7 +31,7 @@ Learn how to {ref}`install isc-kea <install-isc-kea>` or {ref}`install and confi
|
||||
|
||||
Network Time Protocol (NTP) synchronizes time between all devices on a network to within a few milliseconds of Coordinated Universal Time (UTC). Learn more about {ref}`time synchronization <about-time-synchronisation>`.
|
||||
|
||||
Time is primarily synchronized in Ubuntu by `timedatectl` and `timesyncd`. Both utilities are available by default as part of `systemd`. To find out how to configure this service, {ref}`read our how-to guide <timedatectl-and-timesyncd>`.
|
||||
Time is primarily synchronized in Ubuntu by `chrony`. To find out how to configure this service, including Network Time Security (NTS) {ref}`read our how-to guide <chrony-client>`.
|
||||
|
||||
If you want to set up a server to *provide* NTP information, we suggest `chrony`. Learn {ref}`how to serve NTP using chrony <serve-ntp-with-chrony>` with this guide.
|
||||
|
||||
|
@ -7,24 +7,23 @@ Behind this simple description, there is a lot of complexity. There are three ti
|
||||
|
||||
The client software is also a lot more complex than you might expect. It must factor in communication delays and adjust the time in a way that does not upset all the other processes that run on the server. Luckily, all that complexity is hidden from you\!
|
||||
|
||||
By default, Ubuntu uses `chrony` to synchronise time, which is installed by default. See our guide If you would like to know {ref}`use chrony to serve NTP <serve-ntp-with-chrony>`.
|
||||
By default, Ubuntu uses `chrony` to synchronise time, which is installed by default. See our guides, if you would like to know how to {ref}`synchronise time with Chrony <chrony-client>` or {ref}`use chrony to serve NTP <serve-ntp-with-chrony>`.
|
||||
|
||||
Users can optionally use {ref}`timedatectl and timesyncd <timedatectl-and-timesyncd>`.
|
||||
|
||||
## How time synchronisation works
|
||||
|
||||
Since Ubuntu 25.10, `chrony` replace most of `timedatectl`/`timesyncd`.
|
||||
Since Ubuntu 16.04, `timedatectl`/`timesyncd` (which are part of `systemd`) replace most of `ntpdate`/`ntp`.
|
||||
Since Ubuntu 25.10, `chrony` replaces most of `systemd-timesyncd` but still uses systemd's `timedatectl`.
|
||||
|
||||
### About `timesyncd`
|
||||
### About `chrony`
|
||||
|
||||
`timesyncd` replaces not only `ntpdate`, but also the client portion of `chrony` (formerly `ntpd`). So, on top of the one-shot action that `ntpdate` provided on boot and network activation, `timesyncd` now regularly checks and keeps your local time in sync. It also stores time updates locally, so that after reboots the time monotonically advances (if applicable).
|
||||
`chrony` replaces not only `ntpdate`, but also the Simple Network Time Protocol (SNTP) client of `timesyncd` (formerly `ntpd`). So, on top of the one-shot action that `ntpdate` provided on boot and network activation, `chrony` now regularly checks and keeps your local time in sync. It also stores time updates locally, so that after reboots the time monotonically advances (if applicable).
|
||||
|
||||
### About `timedatectl`
|
||||
|
||||
If `chrony` is installed, `timedatectl` steps back to let `chrony` handle timekeeping. This ensures that no two time-syncing services can conflict with each other.
|
||||
If `chrony` is installed, `timedatectl` can still be used to configure basic settings, such as setting the timezone. But more complex configuration needs to be set up using the `chronyc` command. This ensures that no two time-syncing services can conflict with each other.
|
||||
|
||||
`ntpdate` is now considered deprecated in favor of `timedatectl` (or `chrony`) and is no longer installed by default. `timesyncd` will generally keep your time in sync, and `chrony` will help with more complex cases. But if you had one of a few known special `ntpdate` use cases, consider the following:
|
||||
`ntpdate` is now considered deprecated in favor of `chrony` (or `timesyncd`) and is no longer installed by default. `chrony` will generally keep your time in sync and can be set up as a time server, `timesyncd` can help with simpler cases. But if you had one of a few known special `ntpdate` use cases, consider the following:
|
||||
|
||||
- If you require a one-shot sync, use: `chronyd -q`
|
||||
- If you require a one-shot time check (without setting the time), use: `chronyd -Q`
|
||||
|
Reference in New Issue
Block a user