我正在尝试从EC 2(Ubuntu18.04.2LTS)实例中收集时间守护进程的统计信息。我遵循了aws关于如何设置它的指南,它按预期运行。
我需要比较aws和我们使用的另一个服务提供者之间的时间同步差异,这就是为什么我启用了time登录。
但是它不会在/var/log/chrony文件夹中记录任何东西
这是我的配置:
server 169.254.169.123 prefer iburst
pool ntp.ubuntu.com iburst maxsources 4
pool 0.ubuntu.pool.ntp.org iburst maxsources 1
pool 1.ubuntu.pool.ntp.org iburst maxsources 1
pool 2.ubuntu.pool.ntp.org iburst maxsources 2
# This directive specify the location of the file containing ID/key pairs for
# NTP authentication.
keyfile /etc/chrony/chrony.keys
# This directive specify the file into which chronyd will store the rate
# information.
driftfile /var/lib/chrony/chrony.drift
# Uncomment the following line to turn logging on.
log tracking measurements statistics
# Log files location.
logdir /var/log/chrony
# Stop bad estimates upsetting machine clock.
maxupdateskew 100.0
# This directive enables kernel synchronisation (every 11 minutes) of the
# real-time clock. Note that it can’t be used along with the 'rtcfile' directive.
rtcsync
# Step the system clock instead of slewing it if the adjustment is larger than
# one second, but only in the first three clock updates.
makestep 1 3我已经检查了文件夹和所有内容的权限,但是没有日志文件。
希望你们能帮我
发布于 2019-03-07 22:33:59
我刚刚通过以下操作验证了时间日志记录:
sudo apt install chrony/etc/chrony/chronyd.conf中的默认配置编辑为log tracking ...行的注释sudo service chrony restart因此,我对你的测试和我的测试之间的区别最好的猜测是:
发布于 2019-03-07 16:24:28
您是否尝试过查看Chrony是否正在登录到systemd?尝试:
journalctl -u Chronyd.servicehttps://serverfault.com/questions/957211
复制相似问题