zoukankan      html  css  js  c++  java
  • Linux系统 NTP服务

    Ntp时间服务安装配置

    1.  设置时区

    #ln -sf /usr/share/zoneinfo/posix/Asia/Shanghai /etc/localtime

    2.同步硬件时间

    # hwclock -w 

    3.安装ntp服务

    #yum –y install ntp

    4.配置文件/etc/ntp.conf

    driftfile /var/lib/ntp/drift

    restrict -4 default kod notrap nomodify   

    restrict -6 default kod notrap nomodify

    restrict 192.168.2.0 mask 255.255.255.0 nomodify notrap 

    restrict 127.0.0.1

    restrict ::1

    server  127.127.1.0   

    fudge   127.127.1.0 stratum 10

    includefile /etc/ntp/crypto/pw

    keys /etc/ntp/keys

    5.配置client段配置/etc/ntp.conf

    server 192.168.2.176 iburst

    6.启动ntp服务

    #systemctl start ntpd

    #systemctl enable ntpd

  • 相关阅读:
    常用基础命令
    Vim
    Linux目录结构
    稀疏数组
    数据结构概述
    天天用的命令
    Mysql和redis的安装
    回文排列
    URL化
    在word中做复选框打对勾钩
  • 原文地址:https://www.cnblogs.com/devops-docker/p/11507292.html
Copyright © 2011-2022 走看看