Linux Commands

Linux Get Timezone

The Timezone of a computer system is a very important entity that tells your system about the overall environment in which it is operating and helps it to synchronize itself accordingly. At times, you might feel like querying the Timezone of your system maybe for the sake of changing it. Therefore, this guide will show you three different methods of getting the Timezone of your Linux system.

Methods of Getting the Timezone in Linux

For finding out the Timezone of your Linux system, you can make use of any of the following three methods:

Method # 1: Using the TIMEDATECTL Command

In this method, we will be using the TIMEDATECTL command in Linux for querying the Timezone in the manner shown below:

$ timedatectl

The Timezone of our Linux system is highlighted in the following image:

However, along with the Timezone, the above-mentioned command also displayed some other information. If you want the output of this command to be restricted only to the Timezone information, you can modify it as shown below:

$ timedatectl | grep “Time zone”

The modified output of the above-mentioned command is shown in the following image:

Method # 2: Using the CAT Command

Another way of finding out the Timezone of your system makes use of the CAT command in the manner shown below:

$ cat /etc/timezone

The Timezone of our system through this method is shown in the following image:

Method # 3: Using the DATE Command

Another method of querying the Timezone of your system is by making use of the DATE command in the manner shown below:

$ date

The Timezone of our Linux system is highlighted in the following image:

Conclusion

You can instantly find out the Timezone of your Linux system by using any of the three methods shared above. Once you will know the Timezone in which your Linux system is operating, it will become relatively easier for you to manage it.

Similar Posts