• 所有节点配置NTP服务


    主节点:

    打开vim /etc/ntp.conf文件

     1  For more information about this file, see the man pages
     2 # ntp.conf(5), ntp_acc(5), ntp_auth(5), ntp_clock(5), ntp_misc(5), ntp_mon(5).
     3 
     4 driftfile /var/lib/ntp/drift
     5 
     6 # Permit time synchronization with our time source, but do not
     7 # permit the source to query or modify the service on this system.
     8 restrict default kod nomodify notrap nopeer noquery
     9 #restrict -6 default kod nomodify notrap nopeer noquery
    10 
    11 # Permit all access over the loopback interface.  This could
    12 # be tightened as well, but to do so would effect some of
    13 # the administrative functions.
    14 restrict 192.168.133.131 nomodify notrap nopeer noquery #该节点的IP地址
    15 restrict 127.0.0.1
    16 restrict -6 ::1
    17 
    18 # Hosts on local network are less restricted.
    19 restrict 192.168.133.2 mask 255.255.255.0 nomodify notrap #网关和子网掩码
    20 
    21 # Use public servers from the pool.ntp.org project.
    22 # Please consider joining the pool (http://www.pool.ntp.org/join.html).
    23 #server 0.rhel.pool.ntp.org iburst
    24 57 lines yanked    
    25 
    26 server  127.127.1.0
    27 fudge   127.127.1.0 stratum 8

    从节点

    vim vim /etc/ntp.conf

     1 # For more information about this file, see the man pages
     2 # ntp.conf(5), ntp_acc(5), ntp_auth(5), ntp_clock(5), ntp_misc(5), ntp_mon(5).
     3 
     4 driftfile /var/lib/ntp/drift
     5 
     6 # Permit time synchronization with our time source, but do not
     7 # permit the source to query or modify the service on this system.
     8 restrict default  nomodify notrap nopeer noquery
     9 #restrict -6 default kod nomodify notrap nopeer noquery
    10 
    11 # Permit all access over the loopback interface.  This could
    12 # be tightened as well, but to do so would effect some of
    13 # the administrative functions.
    14 
    15 restrict 192.168.133.129  nomodify notrap nopeer noquery#该节点IP地址
    16 restrict 127.0.0.1
    17 restrict -6 ::1
    18 
    19 # Hosts on local network are less restricted.
    20 restrict 192.168.133.2 mask 255.255.255.0 nomodify notrap
    21 
    22 
    23 
    24 #server 2.rhel.pool.ntp.org iburst
    25 #server 3.rhel.pool.ntp.org iburst
    26 server 192.168.133.136 #主机IP地址
    27 fudge 192.168.133.136 stratum 8
  • 相关阅读:
    Membership和Role Providers
    浏览器兼容手册
    手机开发与测试的Firefox插件:User Agent Switcher
    控制input输入框的高度
    纯 CSS3 打造的按钮实例
    CSS对各个浏览器兼容
    网页配色的天然范儿
    Jquery的each里面用return false代替break; return ture 代替continue
    li标签float:left,IE6中第二行会空缺一块,ie8和FF正常,怎么解决?
    用XMLHTTP实现无刷新的与server通信
  • 原文地址:https://www.cnblogs.com/wangleBlogs/p/9619286.html
Copyright © 2020-2023  润新知