• NTP配置文件详解


    driftfile详解:
    我们每一个system clock的频率都有小小的误差,这个就是为什么机器运行一段时间后会不精确. NTP会自动来监测我们时钟的误差值并予以调整.

    但问题是这是一个冗长的过程,所以它会把记录下来的误差先写入driftfile.这样即使你重新开机以后之前的计算结果也就不会丢失了。

    [root@localhost etc]# cat ntp.conf
    # For more information about this file, see the man pages
    # ntp.conf(5), ntp_acc(5), ntp_auth(5), ntp_clock(5), ntp_misc(5), ntp_mon(5).

    driftfile /var/lib/ntp/drift  

    driftfile详解:
    我们每一个system clock的频率都有小小的误差,这个就是为什么机器运行一段时间后会不精确. NTP会自动来监测我们时钟的误差值并予以调整.

    但问题是这是一个冗长的过程,所以它会把记录下来的误差先写入driftfile.这样即使你重新开机以后之前的计算结果也就不会丢失了。

    # Permit time synchronization with our time source, but do not
    # permit the source to query or modify the service on this system.
    restrict default nomodify notrap nopeer noquery

    详解:默认是拒绝所有来源的任何访问

    # Permit all access over the loopback interface. This could
    # be tightened as well, but to do so would effect some of

    # the administrative functions.
    restrict 127.0.0.1
    restrict ::1

    详解:开放本机的任何访问

    # Hosts on local network are less restricted.
    #restrict 192.168.1.0 mask 255.255.255.0 nomodify notrap

    # 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 172.16.10.129 iburst

    详解:指定ntp服务器地址
    #broadcast 192.168.1.255 autokey # broadcast server
    #broadcastclient # broadcast client

    #broadcast 224.0.1.1 autokey # multicast server
    #multicastclient 224.0.1.1 # multicast client
    #manycastserver 239.255.254.254 # manycast server
    #manycastclient 239.255.254.254 autokey # manycast client

    # Enable public key cryptography.
    #crypto

    includefile /etc/ntp/crypto/pw

    详解:配置文件默认开启

    # Key file containing the keys and key identifiers used when operating
    # with symmetric key cryptography.

    keys /etc/ntp/keys

    详解:配置文件默认开启

    # Specify the key identifiers which are trusted.
    #trustedkey 4 8 42

    # Specify the key identifier to use with the ntpdc utility.
    #requestkey 8

    # Specify the key identifier to use with the ntpq utility.
    #controlkey 8

    # Enable writing of statistics records.

    #statistics clockstats cryptostats loopstats peerstats

    # Disable the monitoring facility to prevent amplification attacks using ntpdc
    # monlist command when default restrict does not include the noquery flag. See
    # CVE-2013-5211 for more details.
    # Note: Monitoring will not be disabled with the limited restriction flag.
    disable monitor

  • 相关阅读:
    vmware安装后设置网络
    博客园添加视频
    博客园音乐插件
    去除数组空格 php
    Jmeter 中多线程并发和循环控制器
    Jmeter对返回体中Json格式的reponse的处理
    Jmeter 抓app包 抓到一半不好用了
    Jmeter ResponseAssertion 【Ignore Status】
    JMeter源码导入到Intellij IDEA
    Jmeter 处理Unicode编码转为中文
  • 原文地址:https://www.cnblogs.com/yujianadu/p/14738701.html
Copyright © 2020-2023  润新知