[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 203
  • Last Modified:

Setting the system clock

I have found under Linux that I can change the time using the date command, but when I reboot the machine the time is wrong again.  It appears that for some reason Linux isn't actually changing the system clock.  I'm not really sure what's going on with it.  This problem doesn't occur with Windows NT.  I can set the system clock just fine with NT and after a reboot the time will still be correct.

What am I doing wrong (other than occassionally using NT)?

Thanks,
Rich
0
relleh
Asked:
relleh
1 Solution
 
steve265Commented:
Set the time as you normally would then type "clock -w" this will update your hardware clock.
Unlike other operating systems, Linux maintanes a separate software clock from the hardware clock. This is so that you can have your hardware clock set to universal time, and your software clock will be set to your local time. This is usefull when you have many servers in different time zones. Anyway, "Date" and "Time" use the software clock that Linux maintanes. The "Clock" command manipulates the hardware clock based on the software clock.
0

Featured Post

The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now