Topic
  • 1 reply
  • Latest Post - ‏2012-08-31T10:21:22Z by SystemAdmin
Dritter29
Dritter29
2 Posts

Pinned topic getaddrinfo() returns IPv6 addresses in random order

‏2012-07-18T16:21:24Z |
Hello,

We have been observing a problem on AIX 7.1 with IPv6 addresses. When we execute a call to getaddrinfo() to get the list of IPv6 addresses for a server, the linked list of addresses is coming back in a random order. By this I mean one execution of our test returns the link-local address first where the next execution returns the global address first.

I have attempted to set the AI_EXTFLAGS option on ai_flags and IPV6_PREFER_SRC_PUBLIC on ai_extflags, but that does not appear to have any effect on this behavior.

Is this a known issue/behavior/bug in AIX 7.1? The exact same test case returns the data in a deterministic way (order is always the same) on AIX 6.1

Here is the output of two back to back executions of the test case I have, note in the first one the link-local address is first, whereas in the second the global was returned first.

<example output>
/build/ritter/
ritter@aix7100-00-03-m3 > dump_addrinfo -6 aix7100-00-03-m3
ai_family: AF_INET6
ai_socktype: SOCK_STREAM
ai_protocol: IPPROTO_TCP
ai_addr: fe80::6451:88ff:fee3:c504
ai_canonname: aix7100-00-03-m3

ai_family: AF_INET6
ai_socktype: SOCK_STREAM
ai_protocol: IPPROTO_TCP
ai_addr: fd1c:8167:71a9:0:10:68:9:49
ai_canonname: ?
/build/ritter
ritter@aix7100-00-03-m3 > dump_addrinfo -6 aix7100-00-03-m3
ai_family: AF_INET6
ai_socktype: SOCK_STREAM
ai_protocol: IPPROTO_TCP
ai_addr: fd1c:8167:71a9:0:10:68:9:49
ai_canonname: aix7100-00-03-m3

ai_family: AF_INET6
ai_socktype: SOCK_STREAM
ai_protocol: IPPROTO_TCP
ai_addr: fe80::6451:88ff:fee3:c504
ai_canonname: ?
</example output>

Any help on this would be greatly appreciated.

Thanks!
David Ritter
Rogue Wave Software
Updated on 2012-08-31T10:21:22Z at 2012-08-31T10:21:22Z by SystemAdmin
  • SystemAdmin
    SystemAdmin
    134 Posts

    Re: getaddrinfo() returns IPv6 addresses in random order

    ‏2012-08-31T10:21:22Z  
    Is your issue resolved ? If not could you please provide the AIX Build level details of both your AIX6.1 and AIX7.1 nodes ?

    Thanks