Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to modify the system time zone in Linux

2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

How to modify the system time zone in Linux? I believe that many inexperienced people are at a loss about this, so this article summarizes the causes and solutions of the problem. Through this article, I hope you can solve this problem.

What is Linux system Linux is a free-to-use and free-spread UNIX-like operating system, is a POSIX-based multi-user, multi-task, multi-threaded and multi-CPU operating system, using Linux can run major Unix tools, applications and network protocols.

1. View the system time

# date

You can see that the time zone is EST (US Eastern Standard time), and the normal display should be CST (China Standard time).

2. View the system time zone

# date-R

You can see that the output is

Fri, 21 Nov 2014 00:54:08-0500

Time zone is-5

The normal time zone should be displayed as + 8 (East Zone 8)

3. Make sure the network is smooth, DNS is parsed properly, and try to synchronize the Internet time.

# ntpdate cn.pool.ntp.org

4. View the system time zone configuration file

# cat / etc/sysconfig/clock

5. View the local system time zone configuration file

# strings / etc/localtime

6. Try to modify the system time zone

# tzselect

Select the correct time zone according to the prompts

7. If it can not be solved normally

# cp / usr/share/zoneinfo/Asia/Shanghai / etc/localtime

8. Check the system time zone and system time again, and it has been displayed normally

# date

# date-R

After reading the above, have you mastered the method of how to modify the system time zone in Linux? If you want to learn more skills or want to know more about it, you are welcome to follow the industry information channel, thank you for reading!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report