获取系统时间:
date
date -R 显示时间包含时区
获取硬件时间:
hwclock --show
一、网络时间同步(ntp)
ntpdate time1.aliyun.com
二、手动配置
a.)更新年月日
timedatectl set-time 2018-04-22
b.)更新时分秒
timedatectl set-time 09:30:17
d.)更新时区
timedatectl set-timezone Asia/Shanghai
三、系统时间同步到硬件时间
timedatectl set-local-rtc 1 或者
hwclock --systohc --localtime
四、写入cmos
clock -w