[Samba] Changing from samba 2-2.8a to 3.1 with ldap?

samba3 at mailgate.ru samba3 at mailgate.ru
Mon Feb 2 14:40:43 GMT 2004


> Hi, I am trying to upgrade from old samba to new one, I replaced the 
> samba.schema for open-ldap, changed the smb.conf file to:
> passdb backend = ldapsam:ldap//localhost added ldap amin dn and suffix 
> options but it still aint working with the old ldap records? Do I have 
> to dump the old records and update them with some changes to the ldap 
> with new schema or is samba3 ldap backward compatible? Can anyone 
> describe the process of migrating from old samba to new one with ldap?
> 
> -- 
> To unsubscribe from this list go to the following URL and read the
> instructions:  http://lists.samba.org/mailman/listinfo/samba
> 

yes, you need to update ldap base.
dump it with the help of ldapsearch into some file, e.g. old.ldif:
  ldapsearch -LL -x -h <server> -D "cn=Manager,dc=example,dc=com" -b "dc=example,dc=com" -w "secret" > old.ldif

convert if with convert it with
   convertSambaAccount --input=old.ldif --output new.ldif --changetype=modify --sid=<your-sid>

you may get <your-sid> invoking at PDC:
  net getlocalsid

convertSambaAccount is in <samba-source>/examples/LDAP, chmod it to make executable.

now apply changes to LDAP: ldapmodify -D "cn=Manager,dc=example,dc=com" -w "secret" -f new.ldif


More information about the samba mailing list