↑ ↓ select, Enter open, Esc close

Check system time, time zone and NTP sync

user@server
timedatectl

Shows local time, UTC and RTC as well as the configured time zone. The important lines are System clock synchronized: yes and NTP service: active; otherwise the clock drifts. A deviation of a few minutes is enough to make TOTP codes, Let’s Encrypt validation or log analysis fail.

Note: With systemd-timesyncd, timedatectl timesync-status shows the server and offset. With chrony, chronyc tracking provides these values.

Also searched as

  • server time is wrong
  • is ntp active
  • show server time zone

Related one-liners

All in System and hardware

Read first, then run.

The commands on myline.de act directly on servers, files and databases. A wrong path or placeholder can delete data irreversibly or make a server unreachable.

  • All commands are provided without warranty and are not tested on every system.
  • Understand what a command does before running it, and check every placeholder.
  • Make a backup first and, if possible, try it on a test system.
  • You run commands at your own risk. Liability for damages is excluded to the extent permitted by law.