On Tue, 2026/09/08 at 14:06:17 +0100, Joe wrote:
> On Tue, 8 Sep 2026 11:41:27 +0200
> Nicolas George <[email protected]> wrote:
> 
> > Vincent Lefevre (HE12026-09-08):
> > > But on the problematic machine citron, getaddrinfo with AF_UNSPEC
> > > returns only the IPv6 address. With IPv4, it returns the IPv4
> > > address, though.  
> > 
> > So next step is to examine the DNS requests made by the resolver to
> > see if the issue is that it does not request IPv4 or that it does not
> > get it as a reply.
> > 
> > Regards,
> > 
> 
> With IPv6 on the router and kernel disabled, a new installation of bind9
> still listens on IPv6 addresses. It still attempts IPv6 communications.
> It has to explicitly be told not to. Apt attempts IPv6 first, again
> unless told not to.
> 
> I haven't found any other problems yet, as this is on a server and no
> web browsing occurs. Apt obviously uses http access, but once name
> resolution was fixed and it was told to use IPv4, there has been no
> trouble.
> 
> I expect at some point that my ISP will open up IPv6 access, but it is
> currently giving no expected date.

If you want to prioritise the use IPv4 over IPv6, you can do so by editing
/etc/gai.conf and changing:

  precedence  ::1/128       50
  precedence  ::/0          40
  precedence  2002::/16     30
  precedence ::/96          20
  precedence ::ffff:0:0/96  10

to

  precedence  ::1/128       50
  precedence  ::/0          40
  precedence  2002::/16     30
  precedence ::/96          20
  precedence ::ffff:0:0/96  100

which will then require a restart of resolver and apps that use
getaddrinfo() calls. It shifts the priority of IPv4 from last to first.
Use with caution, and remember where/why you done the change.

-- 
Kind regards,

/S

Attachment: signature.asc
Description: PGP signature

Reply via email to