Package: ntpdate
Version: 1:4.2.0a+stable-2
Severity: normal

ntpdate fails to query a NTP server when the server's hostname resolves
to both IPv6 and IPv4 addresses, if the client has ipv6 kernel module
loaded but no IPv6 connectivity.

As specified per RFC 2553, it should fallback to using IPv4 if IPv6
fails, all the more as it uses getaddrinfo() to resolve the server's
address:

# ntpdate -q ntp.via.ecp.fr
 5 Feb 20:46:12 ntpdate[10069]: sendto(krishna.via.ecp.fr): Network is
unreachable
 5 Feb 20:46:13 ntpdate[10069]: sendto(krishna.via.ecp.fr): Network is
unreachable
 5 Feb 20:46:14 ntpdate[10069]: sendto(krishna.via.ecp.fr): Network is
unreachable
 5 Feb 20:46:15 ntpdate[10069]: sendto(krishna.via.ecp.fr): Network is
unreachable
server 2002:8ac3:802d:1242:204:e2ff:fe10:5c44, stratum 0, offset
0.000000, delay 0.00000
 5 Feb 20:46:16 ntpdate[10069]: no server suitable for synchronization
found

When specifying a IPv4-only hostname, it works fine:

# ntpdate -q ntp.ipv4.via.ecp.fr
server 138.195.130.71, stratum 2, offset 0.024067, delay 0.02591
 5 Feb 20:46:19 ntpdate[10070]: adjust time server 138.195.130.71 offset
0.024067 sec

Below are the DNS entries involved:

# host -t any ntp.via.ecp.fr
ntp.via.ecp.fr is an alias for krishna.via.ecp.fr.

# host -t any krishna.via.ecp.fr
krishna.via.ecp.fr has address 138.195.130.71
krishna.via.ecp.fr has AAAA address
2002:8ac3:802d:1242:204:e2ff:fe10:5c44

-- System Information:
Debian Release: 3.1
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing')
Architecture: i386 (i686)
Kernel: Linux 2.6.10
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)

Versions of packages ntpdate depends on:
ii  libc6                       2.3.2.ds1-20 GNU C Library: Shared libraries an

-- debconf information:
* shared/ntp/servers: ntp.via.ecp.fr


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to