I have a clean Debian 7 installation, and I manually entered the following lines in /etc/ntp.conf:
interface ignore wildcard
interface listen <local_nic_ip>
Hoping that NTP will no longer listen on UDP6, but after a restart, it still does:
5:udp 0 0 <local_nic_ip>:123 0.0.0.0:* 9172/ntpd
6:udp 0 0 127.0.0.1:123 0.0.0.0:* 9172/ntpd
8:udp6 0 0 ::1:123 :::* 9172/ntpd
The command line of NTP shows nothing unusual:
/usr/sbin/ntpd -p /var/run/ntpd.pid -g -u 121:130
How to stop NTP from listening on that UDP6 port?
Best Answer
I have been able to disable IPv6 for NTP on my Debian 5/6/7 and Ubuntu 12.04 this way :
Edit file
/etc/default/ntp
and replaceby
Then, you can keep your directives in
ntp.conf
, they are not ignored :interface ignore wildcard
NTP will also listen on0.0.0.0
interface listen <local_nic_ip>
NTP will only listen on127.0.0.1
(of course)This will results in :
Also, i confirm that
OpenNTPD
listens where you ask him to listen more friendly (no need to edit multiple config files). By default it listens nowhere until you configure it to do so (very secure) ;)In config file, just uncomment line
And add line
Results in :