Checking and Changing the Timezone
This article explains how to set the timezone of Ubuntu 26.04 LTS Server to Japan Standard Time (JST) and how to check time synchronisation (NTP).
A server’s time has two parts: the actual time, which is kept in Coordinated Universal Time (UTC), and the timezone used to display it. Changing the timezone leaves the underlying time untouched and only changes how it is shown.
Reading the Current Settings
Running timedatectl with no arguments shows the time and timezone settings together.
timedatectlkazulog@sv1:~$ timedatectl
Local time: Thu 2026-09-10 23:23:24 UTC
Universal time: Thu 2026-09-10 23:23:24 UTC
RTC time: Thu 2026-09-10 23:23:24
Time zone: UTC (UTC, +0000)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no
kazulog@sv1:~$ date
Thu Sep 10 23:23:24 UTC 2026
kazulog@sv1:~$| Field | Meaning |
|---|---|
Local time | The time as displayed with the timezone applied |
Universal time | The time in UTC. What the server actually keeps |
RTC time | The hardware clock built into the machine |
Time zone | The configured timezone and its offset from UTC |
System clock synchronized | Whether time synchronisation has completed |
NTP service | Whether the synchronisation service is running |
RTC in local TZ | Whether the hardware clock holds local time. no (UTC) is standard on Linux |
Choosing from the List of Timezones
timedatectl list-timezones lists what can be set. This system offers 485 entries.
timedatectl list-timezonesEntries take the form “Region/City”. Filter with grep to find the one you want.
kazulog@sv1:~$ timedatectl list-timezones | wc -l
485
kazulog@sv1:~$ timedatectl list-timezones | grep Tokyo
Asia/Tokyo
kazulog@sv1:~$ timedatectl list-timezones | grep '^America/New'
America/New_York
kazulog@sv1:~$ timedatectl list-timezones | head -5
Africa/Abidjan
Africa/Accra
Africa/Addis_Ababa
Africa/Algiers
Africa/AsmaraChanging the Timezone
sudo timedatectl set-timezone [TIMEZONE]| Field | Value |
|---|---|
| [TIMEZONE] | The timezone to set (Asia/Tokyo for Japan) |
kazulog@sv1:~$ date
Thu Sep 10 23:23:42 UTC 2026
kazulog@sv1:~$ sudo timedatectl set-timezone Asia/Tokyo
kazulog@sv1:~$ date
Fri Sep 11 08:23:42 JST 2026
kazulog@sv1:~$ timedatectl
Local time: Fri 2026-09-11 08:23:42 JST
Universal time: Thu 2026-09-10 23:23:42 UTC
RTC time: Thu 2026-09-10 23:23:42
Time zone: Asia/Tokyo (JST, +0900)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no
kazulog@sv1:~$ ls -l /etc/localtime
lrwxrwxrwx 1 root root 32 Sep 11 08:23 /etc/localtime -> ../usr/share/zoneinfo/Asia/Tokyo
kazulog@sv1:~$ cat /etc/timezone
Asia/Tokyodate jumps nine hours ahead and UTC becomes JST. Universal time has not changed: only the timezone used for display was switched.
The change takes effect immediately, survives a reboot, and applies to the current shell from the next command onwards.
Where the Setting Lives
The timezone is stored as a symbolic link at /etc/localtime, and changing it re-points that link.
The ls -l /etc/localtime line in the example above shows the result. Before the change it pointed at UTC.
kazulog@sv1:~$ ls -l /etc/localtime
lrwxrwxrwx 1 root root 25 Sep 10 23:23 /etc/localtime -> ../usr/share/zoneinfo/UTC
kazulog@sv1:~$ cat /etc/timezone 2>&1
Asia/Tokyo/etc/timezone also exists, but it is not always updated immediately when timedatectl changes the setting. In the example above it still read Asia/Tokyo while /etc/localtime pointed at UTC. To read the current setting, use the output of timedatectl or the target of /etc/localtime.Checking Time Synchronisation (NTP)
The timezone is a display setting; keeping the clock correct is the job of NTP. Ubuntu 26.04 runs chrony by default.
systemctl is-active chrony systemd-timesyncdkazulog@sv1:~$ systemctl is-active chrony systemd-timesyncd 2>&1
active
inactive
kazulog@sv1:~$ systemctl status chrony --no-pager -l | head -6 | cat
● chrony.service - chrony, an NTP client/server
Loaded: loaded (/usr/lib/systemd/system/chrony.service; enabled; preset: enabled)
Active: active (running) since Fri 2026-09-11 08:22:49 JST; 1min 3s ago
Invocation: 9941d684136d4c4588fc2c5ce8bbb390
Docs: man:chronyd(8)
man:chronyc(1)
kazulog@sv1:~$chronyc tracking shows the state of synchronisation and chronyc sources the servers in use.
chronyc tracking
chronyc sourceskazulog@sv1:~$ chronyc tracking | head -6
Reference ID : B97DBE7A (ntp-nts-2.ps5.canonical.com)
Stratum : 3
Ref time (UTC) : Thu Sep 10 23:23:03 2026
System time : 0.000019870 seconds fast of NTP time
Last offset : -0.017891990 seconds
RMS offset : 0.017891990 seconds
kazulog@sv1:~$ chronyc sources
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
^* ntp-nts-2.ps5.canonical.> 2 6 17 51 +21ms[+2725us] +/- 119ms
^+ ntp-nts-3.ps5.canonical.> 2 6 17 51 +17ms[-1165us] +/- 115ms
^+ ntp-nts-2.ps6.canonical.> 2 6 17 52 -27ms[ -45ms] +/- 162ms
^+ ntp-nts-3.ps6.canonical.> 2 6 17 53 -27ms[ -45ms] +/- 151ms
^- ntp-nts-1.ps5.canonical.> 2 6 17 53 +17ms[ -809us] +/- 118ms| Field | Meaning |
|---|---|
Reference ID | The server being followed |
Stratum | Distance from a reference clock. Lower is more accurate |
System time | Difference from NTP time |
^* in chronyc sources | The server currently in use. ^+ is a candidate, ^- is excluded |
System clock synchronized: yes in timedatectl reports the same thing.
Log Timestamps Follow the Timezone
journalctl converts timestamps into the configured timezone when it prints them. The journal records them in UTC, so --utc shows them unconverted.
sudo journalctl --utckazulog@sv1:~$ sudo journalctl -u chrony -n 3 --no-pager | cat
Sep 11 08:23:00 sv1 chronyd[1089]: System clock wrong by 1.102775 seconds
Sep 11 08:23:01 sv1 chronyd[1089]: System clock was stepped by 1.102775 seconds
Sep 11 08:23:01 sv1 chronyd[1089]: System clock TAI offset set to 37 seconds
kazulog@sv1:~$ sudo journalctl -u chrony -n 3 --no-pager --utc | cat
Sep 10 23:23:00 sv1 chronyd[1089]: System clock wrong by 1.102775 seconds
Sep 10 23:23:01 sv1 chronyd[1089]: System clock was stepped by 1.102775 seconds
Sep 10 23:23:01 sv1 chronyd[1089]: System clock TAI offset set to 37 secondsThe same events appear nine hours apart. When correlating logs from several servers, be sure which timezone each one is displaying.
Keeping the Server on UTC
Systems spanning several regions are often left on UTC, with conversion done wherever the data is displayed. The same command switches back.
sudo timedatectl set-timezone UTCkazulog@sv1:~$ sudo timedatectl set-timezone UTC
kazulog@sv1:~$ date
Thu Sep 10 23:24:17 UTC 2026
kazulog@sv1:~$ sudo timedatectl set-timezone Asia/Tokyo
kazulog@sv1:~$ date
Fri Sep 11 08:24:17 JST 2026
kazulog@sv1:~$ timedatectl show
Timezone=Asia/Tokyo
LocalRTC=no
CanNTP=yes
NTP=yes
NTPSynchronized=yes
TimeUSec=Fri 2026-09-11 08:24:17 JST
RTCTimeUSec=Fri 2026-09-11 08:24:17 JSTtimedatectl show prints the settings in a form that is easy to parse, which is useful when a script needs the current timezone.
Setting It at Build Time
The timezone can also be set when the server is built. With cloud-init, one line applies it on first boot. See Automating the Initial Setup with cloud-init.
timezone: Asia/TokyoTest Environment and Session Logs
The examples were captured on Ubuntu 26.04 LTS Server running on CML. The session log of each step can be downloaded below.
| Step | Session log |
|---|---|
| Initial state (UTC) | log |
| The list of timezones | log |
| Changing to Asia/Tokyo | log |
| Checking synchronisation (chrony) | log |
| Comparing log timestamps | log |
| Switching to UTC and back | log |
Reference
timedatectl(1) - systemd documentation
Related articles
- Changing the Hostname on Ubuntu 26.04 LTS Server (hostnamectl)
- Updating Packages on Ubuntu 26.04 LTS Server (apt update / upgrade)
- Setting the Timezone and Time Synchronisation on Ubuntu 26.04 LTS Server
- Creating Users and Granting sudo Privileges on Ubuntu 26.04 LTS Server
- Configuring the SSH Server on Ubuntu 26.04 LTS Server
- Setting Up a telnet Server on Ubuntu 26.04 LTS Server
- Configuring inetd (the Super-Server) on Ubuntu 26.04 LTS Server
- Setting Up a TFTP Server on Ubuntu 26.04 LTS Server (tftpd-hpa)
- FTP Server Setup on Ubuntu 26.04 LTS Server (vsftpd)
- Setting Up a syslog Server on Ubuntu 26.04 LTS Server (rsyslog)
- Managing Services with systemctl and Reading Logs with journalctl on Ubuntu 26.04 LTS Server
- Configuring Automatic Updates on Ubuntu 26.04 LTS Server (unattended-upgrades)
- Automating the Initial Setup of Ubuntu 26.04 LTS Server with cloud-init
- Configuring Kernel Parameters on Ubuntu 26.04 LTS Server (sysctl)
- Configuring the Network on Ubuntu 26.04 LTS Server (Netplan)
- Configuring Name Resolution on Ubuntu 26.04 LTS Server (systemd-resolved)
- Changing the NTP Source on Ubuntu 26.04 LTS Server (chrony)
- Static Routes on Ubuntu 26.04 LTS Server (Netplan)
- How to Install the Latest neovim from the Official Site on Ubuntu 26.04 LTS Server