Skip to content

Time Synchronization (chrony)

Accurate system time is critical for logging, certificate validation, distributed system coordination, and more. Enterprise Linux distributions use chrony as the default NTP client and server, replacing the legacy ntpd. This guide covers chrony installation, NTP source management, timezone configuration, and hardware clock synchronization.

Featurechronyntpd
Sync speedFast convergence, works with intermittent connectionsSlower convergence, needs persistent connection
Resource usageLow memory and CPURelatively higher
VM supportExcellent, handles clock drift wellAverage
EL defaultDefault since EL 7Default in EL 6, removed in EL 8+
AccuracyMicrosecond levelMillisecond level

In EL 8/9, ntpd has been removed from the default repositories. chrony is the only recommended NTP implementation.

chrony is typically pre-installed on EL distributions. If not, install it manually:

Install chrony
sudo dnf install chrony -y
Start and enable at boot
sudo systemctl start chronyd
sudo systemctl enable chronyd
Verify the service status
sudo systemctl status chronyd
List current NTP sources
chronyc sources -v

Column indicators explained:

  • ^* — Currently synced source (active)
  • ^+ — Acceptable alternative source
  • ^- — Not considered for synchronization
  • ^? — Connecting or unknown state
View detailed synchronization status
chronyc tracking

Key fields to watch:

  • System time — Offset between system clock and NTP
  • Last offset — Offset of the last adjustment
  • RMS offset — Root mean square of offsets
  • Frequency — Clock frequency deviation (ppm)

chronyc sourcestats — View Source Statistics

Section titled “chronyc sourcestats — View Source Statistics”
View NTP source statistics
chronyc sourcestats -v

The main configuration file is /etc/chrony.conf.

View current configuration
cat /etc/chrony.conf

The default configuration usually points to the distribution’s NTP pool. You can modify it as needed:

Back up the original configuration
sudo cp /etc/chrony.conf /etc/chrony.conf.bak
Edit the chrony configuration file
sudo vi /etc/chrony.conf

Example NTP server configuration:

/etc/chrony.conf example
# Use global NTP pool servers
pool 2.pool.ntp.org iburst
server time.cloudflare.com iburst
server time.google.com iburst
# Record the rate at which the system clock drifts
driftfile /var/lib/chrony/drift
# Allow the system clock to be stepped in the first three updates
makestep 1.0 3
# Enable kernel synchronization of the real-time clock
rtcsync
# Log directory
logdir /var/log/chrony

Key directive explanations:

  • server — Specify a single NTP server
  • pool — Specify an NTP server pool (auto-resolves multiple addresses)
  • iburst — Send burst requests during initial sync for faster convergence
  • makestep — Allow large time adjustments under specified conditions (params: threshold in seconds + max number of adjustments)
  • rtcsync — Write system time to hardware clock every 11 minutes
Restart chronyd after changes
sudo systemctl restart chronyd
Verify the new NTP sources are active
chronyc sources

To serve time to other hosts on your local network:

Add allowed client subnet to chrony.conf
echo 'allow 192.168.1.0/24' | sudo tee -a /etc/chrony.conf
Restart the service and open the firewall
sudo systemctl restart chronyd
sudo firewall-cmd --permanent --add-service=ntp
sudo firewall-cmd --reload

timedatectl is the systemd utility for managing time and timezone settings.

View system time and timezone status
timedatectl status
List all available timezones
timedatectl list-timezones
Filter for US timezones
timedatectl list-timezones | grep America
Set timezone to US Eastern
sudo timedatectl set-timezone America/New_York
Set timezone to UTC
sudo timedatectl set-timezone UTC
Enable NTP auto-sync
sudo timedatectl set-ntp true
Disable NTP sync (for manual time setting)
sudo timedatectl set-ntp false

After disabling NTP synchronization, you can manually set the system time:

Manually set date and time
sudo timedatectl set-time '2026-03-25 14:30:00'

The hardware clock (RTC) is an independent clock on the motherboard that keeps running when the system is powered off.

Display the hardware clock time
sudo hwclock --show
Write system time to hardware clock
sudo hwclock --systohc
Write hardware clock to system time
sudo hwclock --hctosys
Set hardware clock to UTC
sudo hwclock --systohc --utc

With the rtcsync directive enabled, chrony automatically syncs the system time to the hardware clock every 11 minutes, so manual intervention is rarely needed.

If the system time has drifted significantly and needs immediate correction:

Force an immediate time sync
sudo chronyc makestep

This command instantly adjusts the system time to match the NTP source, regardless of the offset.

Check if chronyd is running
systemctl is-active chronyd
Check if the firewall allows NTP (UDP 123)
sudo firewall-cmd --list-services | grep ntp
Check network connectivity
chronyc activity
View chronyd journal logs
journalctl -u chronyd --no-pager -n 50
View system time offset
chronyc tracking | grep "System time"

The offset should be at the millisecond or microsecond level. If the offset is too large (more than a few seconds), use chronyc makestep to force synchronization.

  1. Keep chrony as the default time service — Do not install ntpd on EL 8/9
  2. Use geographically close NTP sources — Reduces latency and improves accuracy
  3. Configure multiple NTP sources — At least 3-4 sources for redundancy
  4. Use the iburst option — Speeds up initial synchronization
  5. Keep the makestep configuration — Allows large time adjustments at startup
  6. Enable rtcsync — Keeps the hardware clock synchronized
  7. Monitor time offset — Include chronyc tracking in your monitoring system