Skip to main content
RunBook Academy

LinuxLXIII · Cluster Time, DNS and Identity DependenciesNTP skew

NTP skew cluster impact - the silent time bomb

Intermediate⏱ ~10 minchronysystemd-timesyncd

What you'll learn

  • Recognise how NTP skew affects cluster services
  • Identify the symptoms
  • Apply the mitigation patterns
  • Test for NTP skew

Prerequisites

Verified against Ubuntu 24.04 LTS · Debian 12 (Bookworm) · RHEL 9.x · Rocky Linux 9.x · AlmaLinux 9.x · Linux kernel 6.1 LTS / 6.6 LTS · systemd 255+ · OpenSSH 8.7p1 (RHEL 9) / 9.6p1 (Ubuntu 24.04) · nftables 1.0.x · chrony 4.x · Pacemaker 2.1.x · Corosync 3.1.x · 2026-08-09

Not yet marked complete on this device.

NTP skew is the silent time bomb in a cluster. Many services depend on synchronised time; skew breaks them silently. This lesson covers the impact and the mitigation.

What breaks with NTP skew

  • Kerberos: rejects tickets with timestamp skew >5 min. Auth fails cluster-wide.
  • TLS: certificates appear not-yet-valid or expired.
  • Database replication: rejects writes with timestamps in the future or too far in the past.
  • Cluster membership and fencing: corosync token, consensus and failure-detection timers are driven by the clock. A backward step is the dangerous case.
  • Distributed locks: lease expiration may be off.
  • Logs: timestamp correlation breaks across hosts.
  • Backup consistency: snapshot ordering depends on timestamps.

A cluster with even small skew (1 second) can have sporadic issues. With large skew (minutes), it is unusable.

Forward steps are survivable more often, because a timer that has already expired simply fires. They are not safe: a large forward jump expires every lease and token deadline at once, which looks to the peers like a node that went away and came back. Treat any step on a live member as the same class of change.

Symptoms

  • Sporadic “Clock skew too great” errors in Kerberos.
  • TLS handshake failures with “certificate not yet valid”.
  • Database replication errors with timestamps in the future.
  • Log entries from one host show times in the past compared to another.
  • Backups appear to be from the future.
  • A node is fenced with no application fault and no network fault, shortly after someone touched time on it. Check journalctl -u corosync for a lost token around the step.

Mitigation

Multiple NTP sources

Each host syncs to at least two NTP sources. A single source is a single point of failure.

Local NTP server

For larger clusters, run local NTP servers that sync to external sources. Cluster hosts sync to the local servers.

Chrony with leap-second handling

Chrony handles leap seconds correctly. systemd-timesyncd is simpler but may not handle all edge cases.

Monitor offset

Alert on NTP offset > 100 ms. Catching skew early prevents silent failures.

Test for skew

Stop NTP and observe. The unit name is distro-specific, so resolve it rather than guessing:

# RHEL / Fedora / SUSE : chronyd.service  and /etc/chrony.conf
# Debian / Ubuntu      : chrony.service   and /etc/chrony/chrony.conf
CHRONY_UNIT=$(systemctl list-unit-files 'chrony*.service' --no-legend \
  | awk 'NR==1{print $1}')

sudo systemctl stop "$CHRONY_UNIT"

# Watch the offset
chronyc tracking

# Restore
sudo systemctl start "$CHRONY_UNIT"

If a host with skew has Kerberos issues, the cluster recovery from skew is to resync NTP and re-authenticate.

Knowledge check

Knowledge check · 4 questions

  1. Q1. What is the typical Kerberos clock skew limit?

  2. Q2. Small NTP skew (1 second) has no effect on a cluster.

  3. Q3. Which of the following depend on NTP sync? Select all that apply.

  4. Q4. An engineer runs sudo date -s "1 hour ago" on a live Pacemaker cluster member to reproduce a skew bug. What is the most likely immediate result?

Passing score: 75%. Answers are checked in this browser.