CentOS-Stream-10 搭建NTP服务器(二)

客户端:

1.安装chrony。

bash 复制代码
yum install chrony -y
systemctl start chronyd
systemctl enable chronyd
systemctl status chronyd

2.配置文件中注释掉自带服务器同步地址,添加服务器端配置的地址。

bash 复制代码
#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 192.168.0.249 iburst

3.启用NTP。

bash 复制代码
systemctl restart chronyd
timedatectl set-ntp true

4.查看时间源。

bash 复制代码
chronyc sources -v

5.手动同步时间。

bash 复制代码
chronyc -a makestep

6.显示状态。

bash 复制代码
timedatectl
相关推荐
vivo互联网技术17 小时前
从 10 分钟到 1 秒:ES 深度分页任意跳页的三轮优化实战
服务器·数据库·redis·elasticsearch·深度分页
用户8055336980317 小时前
Input 子系统架构:Core、Handler、Driver 三层是怎么协作的
linux·嵌入式
用户8055336980317 小时前
RK-Forge外设系列开篇 - 把板子从「能启动」变成「能用」:Ethernet/SPI/MMC 三个纯接线外设
linux·github·嵌入式
七歌杜金房1 天前
我终于又有了自己的 Linux 电脑
linux·debian·mac
tntxia2 天前
linux curl命令详解_curl详解
linux
扛枪的书生2 天前
Linux 网络管理器用法速查
linux
顺风尿一寸2 天前
Java Socket 内核之旅:从 SocketChannel.read() 到 tcp_recvmsg 与 epoll 的完整调用链路
linux
XIAOHEZIcode3 天前
Ubuntu 终端美化全栈指南:Bash 到 Kitty 踩坑实录
linux·ubuntu·命令行
唐青枫3 天前
别再只会用 cron:Linux systemd Timer 定时任务实战详解
linux