Linux CentOS服務器時間同步阿里雲北京時間

 

1、查看當前服務器時間

[root@iZbp1f0xuq9rc41s6gdvfyZ ~]# date -R
Mon, 27 Apr 2020 10:41:54 +0800

2、安裝ntpdate服務

[root@iZbp1f0xuq9rc41s6gdvfyZ ~]# yum install ntpdate
Loaded plugins: fastestmirror
Determining fastest mirrors

3、直接用域名同步中國上海時間 是阿里雲的服務器

[root@iZbp1f0xuq9rc41s6gdvfyZ ~]# ntpdate ntp1.aliyun.com
27 Apr 10:45:42 ntpdate[6028]: step time server 120.25.115.20 offset 190.621216 sec

 4、查看新時間是否已同步

[root@iZbp1f0xuq9rc41s6gdvfyZ ~]# date -R
Mon, 27 Apr 2020 10:45:51 +0800

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章