[389-users] slapd only listening on IPv6

Gordon Messmer yinyang at eburg.com
Mon Jan 24 00:19:45 UTC 2011


On 01/19/2011 06:11 AM, Ellsworth, Josh wrote:
> I am working on a test 389DS instance and yesterday it started giving me
> trouble. The admin server would not start up correctly. I think that the
> problem is because slapd is not listening on IPv4.
>
> [root at ldaptest ~]# netstat -aunt
> Active Internet connections (servers and established)
> Proto Recv-Q Send-Q Local Address Foreign Address State
...
> tcp 0 0 :::389 :::* LISTEN

That's normal and workable on a standard Linux host.  Is this a 
Debian/Ubuntu system?  They've changed the default behavior, there.

We're looking at a similar problem on the Courier MTA list.  Richard, I 
think the easy fix to this is to override the system default with 
setsockopt:

        int v6only = 0;
        if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY,
                       (char *)&on, sizeof(v6only)) == -1)
            perror("setsockopt IPV6_V6ONLY");

Josh, if this is Debian, you should be able to edit 
/etc/sysctl.d/bindv6only.conf and disable the change that Debian made.



More information about the 389-users mailing list