Home MiscellaneousHow to Change Time Zone in Linux

How to Change Time Zone in Linux

by SupportPRO Admin
Timezone in world map

Setting the correct time zone on a Linux server is important for logs, cron jobs, monitoring tools, and applications. A wrong time zone can create confusion while debugging or tracking events. This guide explains both the modern and legacy ways to change the time zone in Linux.

Step 1: Check the Current Time Zone

Login to the server as root or a user with sudo access and run:

date

Example output:   Wed Sep 12 15:13:14 IST 2012

Here, IST is the current time zone.

Recommended Method (Modern Linux Systems)

This method works on RHEL 7+, CentOS 7+, Rocky Linux, AlmaLinux, Ubuntu 16.04+, Debian, and most systemd-based systems.

Step 2: List Available Time Zones

timedatectl list-timezones
 

You can scroll and find the required region.
For United States, the time zone is:

America/Chicago

Step 3: Set the Time Zone

timedatectl set-timezone America/Chicago
 

This command automatically:

  • Updates /etc/localtime

  • Applies the change system-wide

  • Keeps the hardware clock in sync

Step 4: Verify the Change

timedatectl
 

or

date

You should now see the updated time zone.

Step 5: Enable Time Synchronization 

Modern systems use NTP for accurate time.

timedatectl set-ntp true
 

This ensures your system time stays correct automatically.

Legacy Method (Older Linux Systems)

Use this method only if timedatectl is not available.

Step 6: Navigate to Time Zone Directory

 
cd /usr/share/zoneinfo
ls
 

You will see directories like America, Europe, Asia, etc.

Step 7: Backup Existing Time Zone Configuration

 
mv /etc/localtime /etc/localtime-old

Step 8: Create a Symbolic Link for the New Time Zone

Example for India:

ln -sf /usr/share/zoneinfo/Asia/Kolkata /etc/localtime

Step 9: Update Hardware Clock

 
hwclock –systohc
 

This writes the system time to the hardware clock.

Step 10: (Optional – Legacy Systems Only)

For older RHEL/CentOS (6 and below), update:

vi /etc/sysconfig/clock

Add or modify:

ZONE=”America/Chicago”

This file is not used on modern Linux systems.

Important Notes

  • The rdate command is deprecated and not recommended.

  • Always prefer timedatectl on modern servers.

  • Time synchronization should be enabled to avoid time drift.

Conclusion

Changing the time zone in Linux is simple when using the correct method for your system. Modern Linux distributions make this task easier and safer using timedatectl, while older systems still support manual configuration.

If you require help, contact SupportPRO Server Admin

Server not running properly? Get A FREE Server Checkup By Expert Server Admins - $125 Value

You may also like

Leave a Comment