[Samba] Samba4 / Open LDAP init DB

Leander Schäfer info at netocean.de
Tue May 17 17:27:28 UTC 2016


I have been able to successfully install Samba4 and OpenLDAP and connect 
them via SSL. The file samba.schema is also loaded into OpenLDAP, but 
when I start samba server it looks like it is expecting some basic 
structure. My Question at this point is how to provide this the easisest 
way? Currently the OpenLDAP DB is entirely empty (virgin) so Samba4 
could create anything it needs.

cat /var/log/samba4/log.smbd
   smbldap_open_connection: connection opened
[2016/05/17 19:24:34.065158,  3] 
   ldap_connect_system: successful connection to the LDAP server
[2016/05/17 19:24:34.065319,  2] 
   smbldap_search_domain_info: Problem during LDAPsearch: No such object
[2016/05/17 19:24:34.065340,  2] 
   smbldap_search_domain_info: Query was: dc=MYDOMAIN,dc=LocalDomain, 
[2016/05/17 19:24:34.065359,  0] 
   pdb_init_ldapsam: WARNING: Could not get domain info, nor add one to 
the domain. We cannot work reliably without it.
[2016/05/17 19:24:34.065485,  0] 
   pdb backend ldapsam:"ldap:// 
ldap://Storage-03.MYDOMAIN.LocalDomain/" did not correctly init (error 

cat /usr/local/etc/smb4.conf


   # Basic server settings
   workgroup          = MYDOMAIN
   realm              = MYDOMAIN.LOCALDOMAIN
   netbios name       = STORAGE-03

   # Password backend
   passdb backend         = ldapsam:"ldap:// 
   ldap admin dn          = cn=admin,dc=MYDOMAIN,dc=LocalDomain
   ldap suffix            = dc=MYDOMAIN,dc=LocalDomain
   idmap_ldb:use rfc2307  = Yes
   encrypt passwords      = yes
   invalid users          = root

More information about the samba mailing list