争怎路由网:是一个主要分享无线路由器安装设置经验的网站,汇总WiFi常见问题的解决方法。

如何在Linux/Unix之上绑定ntpd到特定的IP地址

时间:2024/6/9作者:未知来源:争怎路由网人气:

$^' /etc/ntp.conf
样例输出为:
tos minclock 3 maxclock 6
pool 0.freebsd.pool.ntp.org iburst
restrictdefault limited kod nomodify notrap noquery nopeer
restrict -6 default limited kod nomodify notrap noquery nopeer
restrictsource  limited kod nomodify notrap noquery
restrict 127.0.0.1
restrict -6 ::1
leapfile"/var/db/ntpd.leap-seconds.list"
interface ignore wildcard
interface listen 172.16.3.1
interface listen 10.105.28.1
 
重启 ntpd
在 FreeBSD Unix 之上重新加载/重启 ntpd:
$ sudo /etc/rc.d/ntpd restart
或者 在 Debian 和 Ubuntu Linux 之上使用下面的命令:
$ sudo systemctl restart ntp
或者 在 CentOS/RHEL 7/Fedora Linux 之上使用下面的命令:
$ sudo systemctl restart ntpd
 
校验
使用 netstat 和 ss 命令来检查 ntpd 只绑定到了特定的 IP 地址:
$ netstat -tulpn

关键词:怎样在Linux/Unix之上绑定ntpd到特定的IP地址




Copyright © 2012-2018 争怎路由网(http://www.zhengzen.com) .All Rights Reserved 网站地图 友情链接

免责声明:本站资源均来自互联网收集 如有侵犯到您利益的地方请及时联系管理删除,敬请见谅!

QQ:1006262270   邮箱:kfyvi376850063@126.com   手机版