zoukankan      html  css  js  c++  java
  • ntp时间服务器

    # NTP时间同步服务器

    ## 1.1 NTP 简介

    NTP( Network Time Protocol,网络时间协议)是用来使网络中的各个计算机时间同步的一种协

    议。它的用途是把计算机的时钟同步到世界协调时 UTC,其精度在局域网内可达 0.1ms,在互联

    网上绝大多数的地方其精度可以达到 1-50ms。

    NTP 服务器就是利用 NTP 协议提供时间同步服务的。

    **NTP服务端: c701 10.0.0.41**

    **NTP客户端: c702 10.0.0.42**

    ### 1.1.2 NTP服务器安装

    ```shell
    yum -y install ntp
    ```

    ### 1.1.3 配置NTP服务

    ```shell
    vim /etc/ntp.conf

    # restrict default kod nomodify notrap nopeer noquery
    # nomodify客户端可以同步
    restrict default nomodify


    # 将默认时间同步源注释改用可用源
    # 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 ntp1.aliyun.com
    ```

  • 相关阅读:
    python 线程同步
    python 线程模块
    Python线程
    Python 多线程
    Python SMTP发送邮件
    Python Internet 模块
    简单实例
    Socket 对象(内建)方法
    Python 网络编程
    python 数据库错误处理
  • 原文地址:https://www.cnblogs.com/fatzi/p/13353480.html
Copyright © 2011-2022 走看看