成人在线亚洲_国产日韩视频一区二区三区_久久久国产精品_99国内精品久久久久久久

您的位置:首頁技術文章
文章詳情頁

centos7安裝chronyd服務方式

瀏覽:1788日期:2023-10-01 20:59:26
目錄centos7安裝chronyd服務Centos7使用chronyd進行時鐘同步安裝配置文件啟動服務及時區設置驗證服務手動同步時間手動設置時間總結centos7安裝chronyd服務

一、雙節點部署:

ip主機名192.168.100.10controller192.168.100.20compute

二、配置時間同步

1、雙節點安裝chrony服務(這里是使用本地的軟件包進行yum安裝)

[root@controller ~]# yum install -y chrony[root@compute ~]# yum install -y chrony

2、controller修改chrony服務配置文件(在/etc/chrony.conf目錄下)

[root@controller ~]# vi /etc/chrony.conf # Use public servers from the pool.ntp.org project.# Please consider joining the pool (http://www.pool.ntp.org/join.html).#server 0.centos.pool.ntp.org iburst //添加#號#server 1.centos.pool.ntp.org iburst //添加#號#server 2.centos.pool.ntp.org iburst //添加#號#server 3.centos.pool.ntp.org iburst //添加#號server controller iburst //添加這一行# Record the rate at which the system clock gains/losses time.driftfile /var/lib/chrony/drift# Allow the system clock to be stepped in the first three updates# if its offset is larger than 1 second.makestep 1.0 3# Enable kernel synchronization of the real-time clock (RTC).rtcsync# Enable hardware timestamping on all interfaces that support it.#hwtimestamp *# Increase the minimum number of selectable sources required to adjust# the system clock.#minsources 2# Allow NTP client access from local network.allow all //去掉#號# Serve time even if not synchronized to a time source.local stratum 10 //去掉#號# Specify file containing keys for NTP authentication.#keyfile /etc/chrony.keys# Specify directory for log files.logdir /var/log/chrony# Select which information is logged.#log measurements statistics tracking

3、compute 修改chrony配置文件

[root@compute ~]# vi /etc/chrony.conf # Use public servers from the pool.ntp.org project.# Please consider joining the pool (http://www.pool.ntp.org/join.html).#server 0.centos.pool.ntp.org iburst#server 1.centos.pool.ntp.org iburst#server 2.centos.pool.ntp.org iburst#server 3.centos.pool.ntp.org iburstserver 192.168.100.10 iburst //添加這一行# Record the rate at which the system clock gains/losses time.driftfile /var/lib/chrony/drift# Allow the system clock to be stepped in the first three updates# if its offset is larger than 1 second.makestep 1.0 3# Enable kernel synchronization of the real-time clock (RTC).rtcsync# Enable hardware timestamping on all interfaces that support it.#hwtimestamp *# Increase the minimum number of selectable sources required to adjust# the system clock.#minsources 2# Allow NTP client access from local network.#allow 192.168.0.0/16# Serve time even if not synchronized to a time source.#local stratum 10# Specify file containing keys for NTP authentication.#keyfile /etc/chrony.keys# Specify directory for log files.logdir /var/log/chrony# Select which information is logged.#log measurements statistics tracking

4、雙節點重啟服務,并設置開機自啟

[root@controller ~]# systemctl restart chronyd && systemctl enable chronyd[root@compute ~]# systemctl restart chronyd && systemctl enable chronyd

5、controller開啟ntp同步

[root@controller ~]# timedatectl set-ntp true

6、雙節點執行chronyc sources命令,結果中存在以^*開頭的行,則同步成功

[root@controller ~]# chronyc sources210 Number of sources = 1MS Name/IP address Stratum Poll Reach LastRx Last sample ===============================================================================^* controller 10 6 377 27 +186ns[-8404ns] +/- 17us[root@compute ~]# chronyc sources210 Number of sources = 1MS Name/IP address Stratum Poll Reach LastRx Last sample ===============================================================================^* controller 10 6 17 34 -4280ns[ -13us] +/- 328usCentos7使用chronyd進行時鐘同步

最近要做阿里云遷移 IDC 機房,整理下 Linux 運維基線,簡單記錄,以備后用~

安裝# 默認已經安裝$ yum install -y chrony配置文件$ cat /etc/chrony.conf# Use public servers from the pool.ntp.org project.# Please consider joining the pool (http://www.pool.ntp.org/join.html).# 國家服務器server 0.cn.pool.ntp.orgserver 1.cn.pool.ntp.orgserver 2.cn.pool.ntp.orgserver 3.cn.pool.ntp.org# 阿里server ntp.aliyun.com# 騰訊server time1.cloud.tencent.comserver time2.cloud.tencent.comserver time3.cloud.tencent.comserver time4.cloud.tencent.comserver time5.cloud.tencent.com# 蘋果server time.asia.apple.com# 微軟server time.windows.com# 其他server cn.ntp.org.cn# Record the rate at which the system clock gains/losses time.driftfile /var/lib/chrony/drift# Allow the system clock to be stepped in the first three updates# if its offset is larger than 1 second.makestep 1.0 3# Enable kernel synchronization of the real-time clock (RTC).rtcsync# Enable hardware timestamping on all interfaces that support it.#hwtimestamp *# Increase the minimum number of selectable sources required to adjust# the system clock.#minsources 2# Allow NTP client access from local network.#allow 192.168.0.0/16# Serve time even if not synchronized to a time source.#local stratum 10# Specify file containing keys for NTP authentication.#keyfile /etc/chrony.keys# Specify directory for log files.logdir /var/log/chrony# Select which information is logged.#log measurements statistics tracking啟動服務及時區設置# 啟動服務$ systemctl start chronyd# 開機啟動$ systemctl enable chronyd# 查看當前狀態$ systemctl status chronyd# 查看亞洲時區$ timedatectl list-timezones | grep Asia# 設置時區$ timedatectl set-timezone Asia/Shanghai驗證服務# 查看現有的時間服務器$ chronyc sources -v# 查看時間服務器狀態$ chronyc sourcestats -v# 顯示時鐘同步相關參數$ chronyc tracking# 查看當前時區及時間$ timedatectl?手動同步時間# 使用 ntpdate 同步時間$ ntpdate ntp.aliyun.com# chronyd 未啟動時,如下命令同步時間$ chronyd -q 'server pool.ntp.org iburst'# chronyd 啟動時,使用如下命令同步時間$ chronyc -a 'burst 4/4' && sleep 10 && chronyc -a makestep手動設置時間# date 設置時間$ date -s '2021-06-03 19:00:00'# 關閉 ntp 同步后,才可以使用 timedatectl 進行時間設置$ timedatectl set-ntp false# 設置日期和時間$ timedatectl set-time '2021-06-03 19:00:00'# 設置日期$ timedatectl set-time '2021-06-03'# 設置時間$ timedatectl set-time '19:00:00'# 設置完成后,再開啟$ timedatectl set-ntp true總結

以上為個人經驗,希望能給大家一個參考,也希望大家多多支持好吧啦網。

標簽: Linux
成人在线亚洲_国产日韩视频一区二区三区_久久久国产精品_99国内精品久久久久久久
久久97超碰色| 奇米色777欧美一区二区| 国产伦精品一区二区三区四区免费| 麻豆成人在线| 3d成人动漫网站| 亚洲欧美偷拍另类a∨色屁股| 国产成人久久精品77777最新版本 国产成人鲁色资源国产91色综 | 99国产精品久久久久久久久久久| 懂色av一区二区夜夜嗨| 91麻豆精品一区二区三区| 亚洲动漫精品| 色婷婷久久久综合中文字幕| 欧美日本在线观看| 国产午夜精品一区二区三区视频| 亚洲乱码国产乱码精品精98午夜| 日韩综合在线视频| 成人久久18免费网站麻豆 | 色诱亚洲精品久久久久久| 欧美日韩一区在线观看| 国产欧美一区二区精品仙草咪| 亚洲午夜av在线| 99久久国产综合色|国产精品| 影音先锋亚洲精品| 欧美性高清videossexo| 久久精品亚洲麻豆av一区二区 | 91麻豆免费在线观看| 五月激情丁香一区二区三区| 亚洲gay无套男同| 欧美精品自拍| 欧美一区二区免费视频| 亚洲丰满少妇videoshd| 伊人精品成人久久综合软件| 亚洲私人黄色宅男| 2020国产成人综合网| 亚洲综合偷拍欧美一区色| 日韩电影一区二区三区| 色综合中文综合网| 性伦欧美刺激片在线观看| 欧美一级在线免费| 亚洲欧洲一区二区三区| 蜜臀av性久久久久蜜臀aⅴ流畅 | 亚洲黄色av一区| 国产福利91精品一区| 国产深夜精品| 久久人人97超碰com| 麻豆高清免费国产一区| 欧美日韩一区二区三区免费| 欧美日韩亚洲国产综合| 亚洲一区二区av在线| 欧美在线国产| 日韩一区二区三区高清免费看看| 亚洲国产一区二区视频| 午夜久久一区| 欧美一区二区性放荡片| 香蕉成人啪国产精品视频综合网| 91啪九色porn原创视频在线观看| 欧美这里有精品| 亚洲夂夂婷婷色拍ww47| 欧美日韩国产综合视频在线| 欧美日韩你懂得| 一区二区三区在线免费视频| 波多野结衣中文一区| 欧美日韩高清一区二区不卡| 久久av老司机精品网站导航| 尤物在线精品| 中文字幕日韩一区| 一区二区三区四区av| 国产午夜精品久久| 国产成人精品免费视频网站| 久久精品日产第一区二区| 亚洲国产精品精华液2区45| 高清久久久久久| 亚洲欧美清纯在线制服| 亚洲欧洲成人自拍| 99久久伊人网影院| 91精品国产综合久久婷婷香蕉 | 国产在线不卡一区| 在线看日本不卡| 日欧美一区二区| 久久综合狠狠| 蜜臀av一级做a爰片久久| 夜夜精品视频一区二区| 亚洲精品第1页| 日韩天堂av| 亚洲视频免费在线| 国产综合精品| 成人免费在线播放视频| 欧美三级第一页| 中文字幕国产精品一区二区| 亚洲欧美影院| 日本一区二区三区免费乱视频| 91在线观看成人| 国产婷婷一区二区| 亚洲福利免费| 一区二区三区久久| 久久久夜夜夜| 蜜臀久久99精品久久久画质超高清| 久久精品成人| 麻豆国产一区二区| 51精品秘密在线观看| gogo大胆日本视频一区| 国产精品卡一卡二| 久久天天做天天爱综合色| 激情久久综合| 亚洲欧美日韩国产另类专区 | 宅男在线国产精品| a级高清视频欧美日韩| 国产精品久久久久一区| 1000部精品久久久久久久久| 精品日韩在线一区| 欧美日韩亚洲免费| 亚洲国产精品尤物yw在线观看| 色综合久久66| 国产成人亚洲综合色影视| 久久久久久亚洲综合影院红桃 | 精品视频免费在线| 国产一区999| 色婷婷亚洲综合| 亚洲欧美激情视频在线观看一区二区三区| 麻豆精品网站| 国产成人免费在线视频| 国产精品美女久久久久久2018| 欧美人与禽zozo性伦| 亚洲国产综合色| 91精品国产91久久综合桃花 | 91一区二区三区在线播放| 国产精品久久久久久久浪潮网站| 国产视频一区欧美| 午夜精品久久一牛影视| 欧美在线高清视频| 久久99精品久久久久久动态图| 精品国产乱码久久久久久1区2区 | 一区二区精品在线| 理论电影国产精品| 国产色一区二区| 久久综合中文色婷婷| 97久久久精品综合88久久| 亚洲一区在线观看视频| 精品区一区二区| 国产视频不卡| 成人性视频网站| 图片区小说区国产精品视频| 欧美专区日韩专区| 午夜精品亚洲| 青椒成人免费视频| 国产亚洲欧美日韩日本| 色哟哟一区二区三区| 91亚洲资源网| 日日骚欧美日韩| 久久久综合精品| 亚洲欧洲韩国日本视频| 正在播放一区二区| 午夜在线a亚洲v天堂网2018| 成人午夜电影小说| 天堂在线一区二区| 最新欧美精品一区二区三区| 欧美一区二区三区不卡| 亚洲一区免费看| 99精品视频一区二区三区| 亚洲国产精品自拍| 日本韩国欧美在线| 人人超碰91尤物精品国产| 国产蜜臀97一区二区三区| 午夜亚洲福利在线老司机| 成人免费高清视频| 午夜久久福利影院| 欧美国产精品中文字幕| 欧美年轻男男videosbes| 欧美日韩电影在线| 国产不卡视频一区| 日本女优在线视频一区二区| 日韩理论片在线| 26uuu国产电影一区二区| 在线播放亚洲一区| 在线看国产一区二区| 免费日韩视频| 国产视频一区三区| 国产综合网站| 欧美日韩大片一区二区三区| 国产福利不卡视频| 久久99精品国产麻豆不卡| 婷婷中文字幕一区三区| 亚洲已满18点击进入久久| 亚洲视频每日更新| 国产女主播一区| 欧美色手机在线观看| 中国女人久久久| 午夜欧美理论片| 久久91精品国产91久久小草| 中文字幕在线观看一区| 亚洲欧美日韩一区二区| 在线日韩av片| 欧美日韩亚洲高清一区二区| 欧美亚洲国产一卡| 欧美性淫爽ww久久久久无| 欧美日韩在线免费视频| 欧美日本精品一区二区三区| 欧美日韩电影在线| 欧美日韩高清影院| 制服丝袜中文字幕一区|