Get the App
SLTechnology News&Howtos  ›  Development  › 

How to quickly modify the system time under Linux

Shulou Source: shulou.com Published: 2022-06-01 20:47:50 10月04日 Update

This article mainly explains "how to quickly modify the system time under Linux", the content of the article is simple and clear, easy to learn and understand, now please follow the editor's ideas slowly in depth, together to study and learn "how to quickly modify the system time under Linux"!

At the beginning, or there is a saying on the Internet, for example, set the time to 18:30:50 on 2014-07-12.

We will set the date first.

Date-s 20140712

Reschedule

Date-s 18:30:50

It's okay to talk about a machine, but if you have more, you'll get bored. Is there an one-step solution? After several searches, we found that there is!

Date 071218302014 (month, day, hour and year)

This can be done in one step. But! But what, for Linux, this way of writing is too human, too hard to remember. Is there an easier way? After several explorations, I found that there was!

Date-s "20140712 18:30:50"

In this way, it can be achieved in one step, and it is easy to remember. I've been using it for a long time. I don't tell him about ordinary people, Xu.

When the time is set, it will be saved. It's okay if you turn it off normally. The system will be saved once when the system is turned off, but if you may not shut down properly, you can save the settings first.

Hwclock-systohc

Yes, that's what it says. Most of the words on the Internet are

Clock-w

Or

Hwclock-w

If you analyze it carefully, you will know that clock is the soft link of hwclock. The parameter-w is not mentioned at all in hwclock's help and man. I don't know what year-w is written.

Thank you for your reading, the above is the content of "how to quickly modify the system time under Linux". After the study of this article, I believe you have a deeper understanding of how to quickly modify the system time under Linux. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Tags: Time system one step writing learning content time method parameter done that is train of thought situation article method date time more machine fundamental Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Technology Apple OPPO Reno Redmi Shulou Information