mirror of
https://github.com/Erreur32/cheat.git
synced 2024-11-17 17:35:25 +01:00
33 lines
621 B
Text
33 lines
621 B
Text
# Verify ntpd running:
|
|
service ntp status
|
|
|
|
# Start ntpd if not running:
|
|
service ntp start
|
|
|
|
# Display current hardware clock value:
|
|
sudo hwclock -r
|
|
|
|
# Apply system time to hardware time:
|
|
sudo hwclock --systohc
|
|
|
|
# Apply hardware time to system time:
|
|
sudo hwclock --hctosys
|
|
|
|
# Set hwclock to local time:
|
|
sudo hwclock --localtime
|
|
|
|
# Set hwclock to UTC:
|
|
sudo hwclock --utc
|
|
|
|
# Set hwclock manually:
|
|
sudo hwclock --set --date="8/10/15 13:10:05"
|
|
|
|
# Query surrounding stratum time servers
|
|
ntpq -pn
|
|
|
|
# Config file:
|
|
/etc/ntp.conf
|
|
|
|
# Driftfile:
|
|
location of "drift" of your system clock compared to ntp servers
|
|
/var/lib/ntp/ntp.drift
|