centos7.5 时间设置

# ----- 设置时间同步+时区(上海) -----

rpm -qa ntp || yum -y install ntp
systemctl enable ntpd
timedatectl set-ntp true

timedatectl set-timezone Asia/Shanghai