Samba4 provision error with latest OpenLDAP - lt_dlopenext failed

Joe Comeaux joe.comeaux at
Wed Dec 8 09:40:01 MST 2010

SOLVED Samba4 with OpenLDAP on Ubuntu
Samba4 Version 4.0.0alpha14-GIT-UNKNOWN installed from rsync 2010-12-07
OpenLDAP Version 2.4.23
Ubuntu Version 10.10

Attached is a quick run through of the steps i took to get this up and running.

install ubuntu specific packages needed for openldap to configure / compile

apt-get install gcc libltdl-dev libgnutls-dev gnutls-bin libdb-dev
( cyrus-imapd-2.2 may not be needed, this was installed in an attempt
to find sasl.h )
apt-get install cyrus-imapd-2.2
( select no configuration )
apt-get install libsasl2-dev


tar zxvf openldap-stable-20100719.tgz
cd openldap
 CFLAGS="-fno-omit-frame-pointer" `dirname $0`/configure
--with-cyrus-sasl --enable-overlays=mod --enable-modules
 make depend
 make clean all AC_CFLAGS=-g
 make install STRIP=
 cd contrib/slapd-modules/samba4 && make clean all AC_CFLAGS=-g
 cd contrib/slapd-modules/samba4 && make install STRIP=

--at this point openldap is compiled and installed--

( python needed for samba to compile / install // bind needed for DNS
support samba )
apt-get install bind9 python-dev

rsync -a SAMBA_4_0

 cd SAMBA_4_0/source
 ./configure --enable-developer
 make install

cd SAMBA_4_0/source
 setup/provision --realm=EXAMPLE.COM --domain=EXAMPLE \
  --server-role='domain controller' --ldap-backend-type=openldap
--slapd-path=/usr/local/libexec/slapd \
  --password=abCD12#$ --adminpass=abCD12#$

Server Role:           domain controller
Hostname:              voss
NetBIOS Domain:        EXAMPLE
DNS Domain:  
DOMAIN SID:            S-1-5-21-1478023879-1125907918-1911850167
Admin password:        abCD12#$
LDAP Admin User:       samba-admin
LDAP Admin Password:
#u$SSS]4%0W)Sc0uuIZm&ocoa;&HC3P7?u5B.HEd%_6.)xIYVqMD;>IRj(26+BHYUq5vj5 at Vt?Ra7$7_0pEOad at A]:?l]X6EMS)PEv?[jE0$.ENS7u9LCR(mQoIptabqAwp(>j7RGTyb<bSK1;Sc

need to add some parameters to /etc/bind/named.conf.options to allow queries
        pid-file        "/var/run/named/";
        allow-recursion { any; };
        allow-query { any; };
        allow-query-cache { any; };

need to add reference to samba zone in /etc/bind/named.conf.local
	include "/usr/local/samba/private/named.conf";

bind9 bugs about missing version information in libldap libraries
rm /usr/local/lib/
rm /usr/local/lib/
sudo ln -fs /usr/lib/ /usr/local/lib/
sudo ln -fs /usr/lib/ /usr/local/lib/

start bind
/etc/init.d/bind9 start
start openldap
'/usr/local/libexec/slapd' '-F/usr/local/samba/private/ldap/slapd.d'
'-h' 'ldapi://%2Fusr%2Flocal%2Fsamba%2Fprivate%2Fldap%2Fldapi'
start samba
/usr/local/samba/sbin/samba -i -M single -d3

Thanks to mailing list for guidance to get me up and running.
Now to get Active Directory Users and Computers working.
-Joe Comeaux

More information about the samba-technical mailing list