Introduction
The commandtimedatectlis an essential tool in modern Linux distributions that allows you to consult and modify the system's date, time and time zone configuration, as well as manage synchronization through the NTP protocol. With the arrival of systemd, timetatectl became the unified interface for these tasks, replacing antigust tools such as date, hwclock and ntpdate. In this article you will learn from basic concepts to advanced examples that will help you keep your server or workstation always on the right schedule.
What is timetatectl?
timetatectl is part of the systemd package and is run in the user space. You don't need root privileges to show information, but you do need to change the settings. Its output includes local time, universal time (UTC), NTP synchronization status and time zone configured.
Basic syntax
The general format is:timedatectl [OPCIONES] [COMANDO]. Some of the most used options are--no-paskto delete the pagination and--adjust-system-clockwhen changing the time zone. The main commands areset-time, set-timezone, set-ntpandstatus.
Show current settings
Runtimedatectlwithout arguments shows a complete summary. The output includes lines such as:
- Local time: Vie 2025-09-24 10: 30: 00 CEST
- Universal time: Vie 2025-09-24 08: 30: 00 UTC
- RTC time: n / a
- Time zone: Europe / Madrid (CEST, + 0200)
- System clock synchronized: yes
- NTP service: active
- RTC in local TZ: no
Change the date and time
To manually set the date and time is usedtimedatectl set-time 'YYYY-MM-DD HH:MM:SS'. For example:
timedatectl set-time '2025-10-01 15:30:00'
This command temporarily stops NTP synchronization, applies the new value and, if desired, can be reactivated NTP later.
Establish time zone
The list of areas available is obtained withtimedatectl list-timezones. To establish an area, for example America / New _ York, it runs:
timedatectl set-timezone America/New_York
The system immediately updates the clock and saves the configuration in / etc / localtime.
Enable or disable NTP synchronization
The NTP service is controlled withset-ntp. To activate:
timedatectl set-ntp true
To deactivate it:
timedatectl set-ntp false
When active, systemd-timesyncd (or the configured NTP demon) keeps the clock synchronized with time servers.
Practical examples
- Check the state before changing:
timedatectl status - Change to Tokyo time zone and synchronize:
timedatectl set-timezone Asia/Tokyo && timedatectl set-ntp true - Restore the watch to hardware value (RTC):
timedatectl set-local-rtc 0(to use UTC on hardware watch) - temporarily disable NTP for testing:
timedatectl set-ntp false, make changes and then reactivate it.
Common problem solution
If the command returnsFailed to set time: Unit dbus-org.freedesktop.timedate1.service not found, make sure that Systemd is running and you have sudo privileges. Another common symptom is desynchronization after changing the time zone; in this case, it restarts time service withsystemctl restart systemd-timesyncd.
Conclusion
timedatectl is a powerful and simple interface to handle all aspects of the system's watch in Linux. Dominating its use allows you to avoid registration problems, ensure log consistency and ensure that time-dependent applications work properly. With the examples and explanations presented, you are ready to set date, time and time zone in any distribution based on systemd.


