Linux系统时间同步方法
发布时间:2024-12-24 09:15       
Linux系统之时间同步方法
一、使用NTP服务时间同步
1.安装ntp
[root@node ~]# yum -y install ntp
C++
2.启动ntp服务
[root@node ~]# systemctl start ntpd
[root@node ~]# systemctl enable ntpd
Created symlink from /etc/systemd/system/multi-user.target.wants/ntpd.service to /usr/lib/systemd/system/ntpd.service.
C++
3.查看ntp服务
[root@node ~]# systemctl status ntpd
● ntpd.service - Network Time Service
Loaded: loaded (/usr/lib/systemd/system/ntpd.service; enabled; vendor preset: disabled)
Active: active (running) since Thu 2022-08-04 08:00:47 CST; 7h left
Main PID: 20746 (ntpd)
Tasks: 1
Memory: 768.0K
CGroup: /system.slice/ntpd.service
└─20746 /usr/sbin/ntpd -u ntp:ntp -g
Aug 04 08:00:47 node ntpd[20746]: Listen normally on 6 lo ::1 UDP
Copyright © 2018-2025 华太云 版权所有