天天看點

centos7 安裝ntp服務

服務端

    1.服務端安裝ntpd服務

    yum install  ntp

    2.修改配置檔案,配置檔案在/etc/ntpd.conf

    注釋或者删除以下四行

    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  127.127.1.0

    3.啟動ntp

    systemctl restart ntpd

用戶端:

    ntpdate 192.168.3.184

繼續閱讀