Firewalled NTP on Redhat - ntpdate works, but ntpq doesn't

Herta Van den Eynde herta.vandeneynde at gmail.com
Fri May 18 21:27:18 UTC 2007


On 18/05/07, Young, Mike <Mike.Young at atosorigin.com> wrote:
> Good info, but does ntpq use different ports than ntpdate?  After all, ntpdate works, but ntpq does not.

It's easy to check.  Open two terminal windows on your client.
In the first, run
# tcpdump -nn host 213.239.194.210
(213.239.194.210 is the address of a public ntp server, but you can
substitute it with one of your own)
In the second run
# ntpdate -q 213.239.194.210

On my laptop, it results in:

23:20:10.906836 IP 182.188.1.103.32890 > 213.239.194.210.123: NTPv4,
Client, length 48
23:20:10.938987 IP 213.239.194.210.123 > 182.188.1.103.32890: NTPv4,
Server, length 48
23:20:10.939104 IP 182.188.1.103.32890 > 213.239.194.210.123: NTPv4,
Client, length 48
23:20:10.971364 IP 213.239.194.210.123 > 182.188.1.103.32890: NTPv4,
Server, length 48
23:20:10.971444 IP 182.188.1.103.32890 > 213.239.194.210.123: NTPv4,
Client, length 48
23:20:11.002340 IP 213.239.194.210.123 > 182.188.1.103.32890: NTPv4,
Server, length 48
23:20:11.002434 IP 182.188.1.103.32890 > 213.239.194.210.123: NTPv4,
Client, length 48
23:20:11.037272 IP 213.239.194.210.123 > 182.188.1.103.32890: NTPv4,
Server, length 48

So, my laptop uses a high port value, the server uses 123.

Kind regards,

Herta




More information about the redhat-list mailing list