[ntp:questions] ipv6 support on linux - bind problem

Maurice Janssen mauricej at xs4all.nl
Sat Apr 7 20:35:57 UTC 2007


On Sat, 7 Apr 2007 19:33:52 +0000 (UTC), Maurice Janssen wrote:
>On Sat, 07 Apr 2007 11:14:04 -0700, Wolfgang S. Rupprecht wrote:
>>I've seen this problem with other programs under linux's ipv6.  The
>>problem is that the linux stack unlike the Kame stack used in BSD's
>>uses mapped ipv4 addresses in ipv6.  If one opens up a whildcard
>>listening socket for both the ipv4 stack (with AF_INET) and then again
>>for the ipv6 stack (with AF_INET6), one ends up trying to open the v4
>>port a second time through the mapped-address.  The trick is to only
>>open up the AF_INET6 socket - it implies the ipv4 mapping.
>
>Another option:
>echo 1 > /proc/sys/net/ipv6/bindv6only

Perhaps I should add that one should test this first.  Other daemons
might rely on the default behaviour and bind to ipv6 addresses only,
assuming that the service will also be running on ipv4 addresses.

-- 
Maurice




More information about the questions mailing list