Re: Configuring which interface for ntpd
Originally Posted by
memilanuk
Hello,
I installed ntpd on my U9.10 server. I set the upstream servers to what I wanted in /etc/ntp.conf, but I can't find anyplace to limit what interface it listens on. Judging by the below, it seems to be 'attached' to both eth0 (192.168.11.14), eth1 (10.0.0.1) and l0 (127.0.0.1), but I'm not sure if it's 'listening' or not since it doesn't have a 'LISTEN' under 'State'... but then again dnsmasq isn't listed as 'LISTEN' for bootp/dhcp (tcp67/68), but I know thats working...
Code:
root@rahvin:~# netstat -ntulp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:53 0.0.0.0:* LISTEN 1329/dnsmasq
tcp 0 0 10.0.0.1:22 0.0.0.0:* LISTEN 1033/sshd
tcp6 0 0 :::53 :::* LISTEN 1329/dnsmasq
udp 0 0 10.0.0.1:123 0.0.0.0:* 1454/ntpd
udp 0 0 192.168.11.14:123 0.0.0.0:* 1454/ntpd
udp 0 0 127.0.0.1:123 0.0.0.0:* 1454/ntpd
udp 0 0 0.0.0.0:123 0.0.0.0:* 1454/ntpd
udp 0 0 0.0.0.0:53 0.0.0.0:* 1329/dnsmasq
udp 0 0 0.0.0.0:67 0.0.0.0:* 1329/dnsmasq
udp 0 0 0.0.0.0:68 0.0.0.0:* 739/dhclient3
udp6 0 0 fe80::a00:27ff:feff:123 :::* 1454/ntpd
udp6 0 0 fe80::a00:27ff:fe2e:123 :::* 1454/ntpd
udp6 0 0 ::1:123 :::* 1454/ntpd
udp6 0 0 :::123 :::* 1454/ntpd
udp6 0 0 :::53 :::* 1329/dnsmasq
root@rahvin:~#
If you have any ideas how to limit what interface ntpd listens or offers services on, I'd appreciate it. If I'm misreading the above please point me in the right direction
TIA,
Monte
I am pretty sure that it is not actually listening or doing anything on your connections. NTPD doesn't listen for information usually. When the timer goes off for it to check if your time is correct it turns on a connection and asks for the information. There is never (well shouldn't be unless someone is trying to hack your NTPD) an inbound connection that NTPD doesn't start itself. As to on which interface. You don't need to specify one. NTPD just searches each on until it finds a valid connection to the timeserver you are asking it to you. Then it does it's thing.
I am now back to help the Proton Gaming phase!
OS: Kubuntu 22.10
Bookmarks