Answers:
要停止ntpd:
sudo /etc/init.d/ntp stop
要么
sudo service ntp stop
为了防止它在启动时启动:
sudo update-rc.d -f ntp remove
对于systemd,两个命令是:
sudo systemctl stop ntp
sudo systemctl disable ntp
输出(我认为警告可以忽略)
ntp.service is not a native service, redirecting to systemd-sysv-install
Executing /lib/systemd/systemd-sysv-install disable ntp
insserv: warning: current start runlevel(s) (empty) of script `ntp' overrides LSB defaults (2 3 4 5).
insserv: warning: current stop runlevel(s) (1 2 3 4 5) of script `ntp' overrides LSB defaults (1).
insserv: warning: current start runlevel(s) (empty) of script `ntp' overrides LSB defaults (2 3 4 5).
insserv: warning: current stop runlevel(s) (1 2 3 4 5) of script `ntp' overrides LSB defaults (1).
校验:
systemctl is-enabled ntp
输出量
ntp.service is not a native service, redirecting to systemd-sysv-install
Executing /lib/systemd/systemd-sysv-install is-enabled ntp
disabled
systemd-timesyncd.service
ntp
。