You can perform the below steps using root or sudo users.
- Check your current timezone by executing the following commands.
- As you can see above that, the current time zone is UTC. Now, if we want to change to another timezone.
- Now, we want to change the timezone. First, we need to list out all the zones. You can check it by executing the below command.
# timedatectl list-timezones
- Those are the timezones. Now, if we wish to change to “Africa/Juba”. Now, we will grep the “Juba” from the timezone by fire below command.
# timedatectl list-timezones | grep juba
- So, finally we have identified our timezone, lets change it to it. Follow the below command in order to change the timezone.
# timedatectl set-timezone africa/juba
- By performing the above command, we can see that our timezone has been changed.