Guide: Configuring NTP on Debian 12 with systemd-timesyncd
In this example, we’ll use Debian’s built-in NTP client to set up your preferred time servers.
Enable systemd-timesyncd
Check current status:
timedatectl status
Look for: NTP service: active. If inactive, enable it:
sudo systemctl enable --now systemd-timesyncd
Verify synchronization:
timedatectl timesync-status
Set NTP Servers
Edit the configuration file:
sudo nano /etc/systemd/timesyncd.conf
In the [Time] section, add or uncomment and modify next lines:
[Time]
NTP=0.fi.pool.ntp.org 1.fi.pool.ntp.org
FallbackNTP=0.debian.pool.ntp.org 1.debian.pool.ntp.org
NTP→ your primary servers (Replace with your preferred NTP sources).FallbackNTP→ backup servers if primaries fail.
Apply Changes
Restart the service:
sudo systemctl restart systemd-timesyncd
Check status:
timedatectl status
Verify synchronization:
timedatectl timesync-status
Set Time Zone
List available time zones
timedatectl list-timezones
You can scroll or grep through the list, for example:
timedatectl list-timezones | grep Europe
Set your desired time zone
sudo timedatectl set-timezone <TIME ZONE>
Verify the change
timedatectl status
Now your Debian 12 uses your selected NTP servers for time synchronization.
Member discussion