Samba4 + OpenLDAP - problem

Motaz Diab forzamotaz at yahoo.com
Thu Aug 6 12:59:02 MDT 2009


Thank you for your response and I have done as you told me but my problem
isn't solved
where I installed 
db4-4.7.25-11.fc11.i586
db4-cxx-4.7.25-11.fc11.i586
db4-devel-4.7.25-11.fc11.i586
db4-utils-4.7.25-11.fc11.i586
and downloaded openldap-2.4.17.tgz
cd /downloads/openldap-2.4.17
env CPPFLAGS="-D_GNU_SOURCE
-I/usr/lib/perl5/5.10.0/i386-linux-thread-multi/COR
E" ./configure --prefix=/opt/openldap --enable-debug --enable-dynamic
--enable-syslog --enable-proc
title --enable-ipv6 --enable-local --enable-slapd --enable-aci
--enable-cleartext --enable-crypt --
disable-lmpasswd --enable-spasswd --enable-modules --enable-rewrite
--enable-rlookups --enable-slap
i --enable-slp --enable-wrappers --enable-backends=mod --enable-bdb
--enable-dnssrv --enable-hdb --
enable-ldap --enable-monitor --disable-ndb --enable-memberof --enable-refint
--enable-syncprov --en
able-translucent --enable-deref --enable-dds --with-subdir=ldap
--with-cyrus-sasl --with-threads --
with-tls=gnutls --enable-sql=mod

make depend
make
make install

and downloaded samba-4.0.0alpha8.tar.gz
cd /downloads/samba-4.0.0alpha8/source4
./configure --prefix=/opt/samba4 --enable-debug --enable-developer
--with-logfilebase=/opt/samba4/logs
gmake
make install


and then I try to configure samba4 with openldap by:
cd /downloads/samba-4.0.0alpha8/source4
setup/provision-backend --realm=uok.edu.sy --domain=uok.edu.sy
--ldap-admin-pass=secret --ldap-backend-type=openldap
--ldap-backend-port=389 --server-role='domain controller'

Your openldap Backend for Samba4 is now configured, and is ready to be
started
Server Role:         domain controller
Hostname:            dc1
DNS Domain:          uok.edu.sy
Base DN:             DC=uok,DC=edu,DC=sy
LDAP admin user:     samba-admin
LDAP admin password: secret
Start slapd with:    slapd -f /opt/samba4/private/ldap/slapd.conf -h
ldapi://%2Fopt%2Fsamba4%2Fpriv
ate%2Fldap%2Fldapi -h ldap://0.0.0.0:389
Run provision with: --ldap-backend=ldapi --ldap-backend-type=openldap
--password=secret --username=
samba-admin --realm=uok.edu.sy --domain=UOK.EDU.SY --server-role='domain
controller'

and I replaced hdb by bdb in /opt/samba4/private/ldap/slapd.conf + added
these modules to modules.comf:
modulepath	/opt/openldap/libexec/openldap
moduleload back_bdb.so
moduleload deref.so
moduleload refint.so
moduleload memberof.so
moduleload syncprov.so 

when I tried to start ldap server by:
/opt/openldap/libexec/slapd -d 1 -f /opt/samba4/private/ldap/slapd.conf -h
ldapi://%2Fopt%2Fsamba4%2Fprivate%2Fldap%2Fldapi -h ldap://0.0.0.0:389
setup/provision --ldap-backend=ldap://127.0.0.1 --ldap-backend-type=openldap
--password=secret --username=samba-admin --realm=uok.edu.sy
--domain=UOK.EDU.SY --server-role='domain controller' 

I got these errors:

backend_startup_one: starting "cn=Samba"
backend_startup_one: starting
"cn=Schema,cn=Configuration,dc=uok,dc=edu,dc=sy"
bdb_db_open: database "cn=Schema,cn=Configuration,dc=uok,dc=edu,dc=sy":
dbenv_open(/opt/samba4/priv
ate/ldap/db/schema).
bdb_monitor_db_open: monitoring disabled; configure monitor database to
enable
bdb_dn2entry("cn=schema,cn=configuration,dc=uok,dc=edu,dc=sy")
=> bdb_dn2id("cn=schema,cn=configuration,dc=uok,dc=edu,dc=sy")
<= bdb_dn2id: get failed: DB_NOTFOUND: No matching key/data pair found
(-30988)
backend_startup_one: starting "cn=Configuration,dc=uok,dc=edu,dc=sy"
bdb_db_open: database "cn=Configuration,dc=uok,dc=edu,dc=sy":
dbenv_open(/opt/samba4/private/ldap/d
b/config).
bdb_dn2entry("cn=configuration,dc=uok,dc=edu,dc=sy")
=> bdb_dn2id("cn=configuration,dc=uok,dc=edu,dc=sy")
<= bdb_dn2id: get failed: DB_NOTFOUND: No matching key/data pair found
(-30988)
backend_startup_one: starting "dc=uok,dc=edu,dc=sy"
bdb_db_open: database "dc=uok,dc=edu,dc=sy":
dbenv_open(/opt/samba4/private/ldap/db/user).
bdb_dn2entry("dc=uok,dc=edu,dc=sy")
=> bdb_dn2id("dc=uok,dc=edu,dc=sy")
<= bdb_dn2id: get failed: DB_NOTFOUND: No matching key/data pair found
(-30988)
slapd starting

so when I executed this command:

setup/provision --ldap-backend=ldap://127.0.0.1 --ldap-backend-type=openldap
--password=secret --username=samba-admin --realm=uok.edu.sy
--domain=UOK.EDU.SY --server-role='domain controller' 

I got this output:

Setting up secrets.ldb
Setting up the registry
Setting up templates db
Setting up idmap db
schema_fsmo_init: no schema dn present: (skip schema loading)
naming_fsmo_init: no partitions dn present: (skip loading of naming contexts
details)
pdc_fsmo_init: no domain dn present: (skip loading of domain details)
schema_fsmo_init: no schema dn present: (skip schema loading)
naming_fsmo_init: no partitions dn present: (skip loading of naming contexts
details)
pdc_fsmo_init: no domain dn present: (skip loading of domain details)
Setting up sam.ldb attributes
Setting up sam.ldb rootDSE
Erasing data from partitions
schema_fsmo_init: no schema head present: (skip schema loading)
naming_fsmo_init: no partitions dn present: (skip loading of naming contexts
details)
pdc_fsmo_init: no domain object present: (skip loading of domain details)
Pre-loading the Samba 4 and AD schema
Adding DomainDN: DC=uok,DC=edu,DC=sy (permitted to fail)
Traceback (most recent call last):
  File "setup/provision", line 192, in <module>
    ldap_backend_type=opts.ldap_backend_type)
  File "bin/python/samba/provision.py", line 1052, in provision
    ldap_backend_type=ldap_backend_type)
  File "bin/python/samba/provision.py", line 801, in setup_samdb
    "DOMAIN_OC": domain_oc
  File "bin/python/samba/provision.py", line 187, in setup_add_ldif
    ldb.add_ldif(data)
  File "bin/python/samba/__init__.py", line 192, in add_ldif
    self.add(msg)
_ldb.LdbError: (8, 'LDAP error 8 LDAP_STRONG_AUTH_REQUIRED -  <modifications
require authentication
> <>')

I don't know where is the wrong 
was there anything I forgot it?



-- 
View this message in context: http://www.nabble.com/Samba4-%2B-OpenLDAP---problem-tp24644818p24852521.html
Sent from the Samba - samba-technical mailing list archive at Nabble.com.



More information about the samba-technical mailing list