CentOS modification time tutorial

Source: Internet
Author: User

CentOS modification time tutorial

When we use CentOS, we find that the bios system time is incorrect. How can we modify this time?
The method is as follows:

[Root @ alvin ~] # Hwclock--show # display the current bios time

Sunday, June 17, June 28, 2015-28 seconds-0.826052 seconds

[Root @ alvin ~] # Date # display the current time

Tuesday, June 30, 2015 16:32:03 CST

[Root @ alvin ~] # Hwclock--systohc # synchronize bios with the current time (--hctosys indicates that bios time is used for synchronization)

[Root @ alvin ~] # Hwclock--show

Tuesday, June 30, 2015 31 seconds-1.040833 seconds

[Root @ alvin ~] # Date

Tuesday, June 30, 2015 16:33:41 CST

[Root @ alvin ~] #

The method for modifying the current time is as follows:

[Root @ alvin ~] # Date-s 06/18/15 # change the date to June 18, 2015

Thursday, June 18, 2015 00:00:00 CST

[Root @ alvin ~] # Date

Thursday, June 18, 2015 00:00:11 CST # Note: The time is 00:00:11.

[Root @ alvin ~] # Date-s 14:20:50 # change the time To 14:20:50

Thursday, June 18, 2015 14:20:50 CST

[Root @ alvin ~] #

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.