[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

getaddrinfo address ordering [Re: IPv6 transition architecturediscussion]



On Mon, 25 Nov 2002, Keith Moore wrote:
[...]
> at least not right now.  attempts to talk to v6 sites typically
> time out (which is annoying because the v6 addresses are tried first -
> another thing which needs to be fixed)

Do I sense this as a voice for support to modify or at least explore the 
current de-facto standard ordering?

> > We were considering turning on 6to4 by 
> > default when there are no routing advertisements. This working group 
> > has dissuaded us from doing so. If we did turn on 6to4, we would want 
> > to add some extra smarts to getaddrinfo to list IPv4 addresses first 
> > when 6to4 is in use to reduce the load on the relays. 
> 
> it turns out that you need the address ordering to be sensitive to both
> network configuration and to the particular application.  some apps will
> be v4 by default, others will be v6 default, others will be exclusively 
> one or the other.

There are already some variables that affect this, namely:

 1) whether the DNS lookup produces A, AAAA, or both; ie "remote 
site configuration"

 2) what ordering for DNS records is used when both are used
(default is AAAA first everywhere I know, no possibility to change that)

 3) whether the application uses AF_INET, AF_INET6 or AF_UNSPEC
(with server apps, this is even a bit muddier.)

These help quite a bit, but I guess adding some getaddrinfo hint like
AI_PREFERV4 or AI_PREFERV6 could be added in the case that DNS lookup
returns both addresses, you use AF_UNSPEC and you want to influence the
default DNS record ordering.

-- 
Pekka Savola                 "Tell me of difficulties surmounted,
Netcore Oy                   not those you stumble over and fall"
Systems. Networks. Security.  -- Robert Jordan: A Crown of Swords