Topic Contributors
creator avatar  
mreschke
Matthew Reschke
Site Developer
Created: Jun 7th, 2011
Updated: Jun 7th, 2011
File
Download Selected (zip)
Download Selected (tar.gz)
Edit
Select All
Select None
View
Detail
Detail Preview
Icons
Preview
Show Hidden
Hide Hidden
Full Manager
Reset Defaults
Open In New Tab
Open In New Window
List Archive Contents
Download File
Open
Download Folder (as .zip)
Set Date Time in Linux
Post # 255 permalink Topic #253 by mreschke on 2011-06-07 12:40:06 (viewed 455 times)
Table of Contents

Info
I need to adjust the date and time in linux quite often and sometimes its a pain to google the correct procedure of hardware clock and system clock. So here it is.

This will change both your system clock and hardware clock together
sudo date -s "7 JUN 2011 12:44:00"; sudo hwclock --systohc

  1. Show System Clock date
  2. Show Hardware Clock sudo hwclock --show
  3. Change System Clock sudo date -s "2 OCT 2006 18:00:00"
  4. Set Hardware Clock from System Clock sudo hwclock --systohc
  5. Set System Clock from Hardware Clock sudo hwclock --hctosys