centos ntp 国内时间服务器地址
以下是一些在中国可用的 NTP 时间服务器地址,您可以在 CentOS 中使用它们来同步系统时间:
159彩票网ntp.aliyun.com
ntp1.aliyun.com
159彩票网ntp2.aliyun.com
ntp3.aliyun.com
159彩票网cn.pool.ntp.org
cn.ntp.org.cn
要将 CentOS 的系统时间与上述时间服务器同步,请按照以下步骤操作:
159彩票网使用 root 用户登录到 CentOS 系统。
安装 NTP 服务,您可以使用以下命令:
Copy code
yum install ntp
打开 /etc/ntp.conf 文件并找到以下行:
Copy code
159彩票网server 0.centos.pool.ntp.org
159彩票网server 1.centos.pool.ntp.org
server 2.centos.pool.ntp.org
server 3.centos.pool.ntp.org
159彩票网注释掉上述行,并添加以下行:
Copy code
server ntp.aliyun.com
159彩票网注意:如果您要使用其他时间服务器,请将上述地址替换为所需的时间服务器地址。
保存并关闭 /etc/ntp.conf 文件。
启动 NTP 服务并设置为开机自启动,使用以下命令:
bash
Copy code
159彩票网systemctl start ntpd
159彩票网systemctl enable ntpd
159彩票网等待一段时间,让系统时间与 NTP 时间服务器同步。
159彩票网通过以上步骤,您可以将 CentOS 系统的时间与可靠的国内 NTP 时间服务器同步。