Thanks HÃ¥vard and Chuck, not disagreeing below since I am genuinely confused, just trying to get it straight in my head.

On 04/28/2011 10:00, Chuck Swiger wrote:
On Apr 28, 2011, at 3:23 AM, Havard Eidnes wrote:
www.apple.com.  281 IN CNAME www.isg-apple.com.akadns.net.
www.isg-apple.com.akadns.net. 60 IN CNAME www.apple.com.edgekey.net.
www.apple.com.edgekey.net. 17295 IN CNAME e3191.c.akamaiedge.net.
...

As a matter of terminology, in the quoted example, I see a chain
of three CNAME records.  That's not what I would call an empty
CNAME chain.

What I do see, though, is a CNAME chain of three CNAME records,
but where the ultimate target of the CNAME chain exists, but does
not have any data of the requested type.  Therefore, in the DNS
you get a NOERROR status code, and an answer section which does
not contain any records of the requested type.

Agreed.  Akamai's EdgeSuite doesn't provide IPv6 AAAA records at this time, but 
e3191.c.akamaiedge.net does have an A record.

I understand what you're saying, but I've always referred to such a thing as an "empty CNAME chain" because it doesn't result in an address record at the end. Is there a more proper term for it?

should getaddrinfo() return EAI_NONAME or EAI_FAIL?

RFC 3493 says:

   [EAI_NONAME]    The name does not resolve for the supplied
                   parameters.  Neither nodename nor servname were
                   supplied.  At least one of these must be supplied.

   [EAI_FAIL]      A non-recoverable error occurred when attempting to
                   resolve the name.

Which means that it should probably return EAI_NONAME; it's the least
bad error code among the ones listed in RFC 3493 for getaddrinfo(),
although one should not be mislead to think that this means that the
DNS said NXDOMAIN.

+1 to this analysis as well.

The original question that started me down the rabbit hole was, "What error code should 'ping6 www.apple.com' return?" What confuses me here is that the node does actually "exist" in the sense that there is _an_ address record for it. So attempting to look at this from the standpoint of a user, the error message I get back (in our case, "hostname or servname not provided, or not known") doesn't make any sense. (Although admittedly the "does not resolve for the supplied parameters" part of the definition does seem to.) Since for the purpose of ping6 no AAAA record at the end of the chain is a non-recoverable error, _FAIL ("non-recoverable failure in name resolution") seems to make more sense.

Is it possible that what we need is a new error code to designate "something exists here, just not what you asked for?" If _NONAME is intended to indicate that it seems overloaded. Alternatively I think we need to improve the language of our error messages. :-/


Thanks again,

Doug

--

        Nothin' ever doesn't change, but nothin' changes much.
                        -- OK Go

        Breadth of IT experience, and depth of knowledge in the DNS.
        Yours for the right price.  :)  http://SupersetSolutions.com/

_______________________________________________
bind-users mailing list
bind-users@lists.isc.org
https://lists.isc.org/mailman/listinfo/bind-users

Reply via email to