[Samba] migrate Windows Active Directory Users to Samba+LDAP

morgan at tuxedo.darktech.org morgan at tuxedo.darktech.org
Tue Oct 20 13:32:08 MDT 2009

On Tue 20/10/09  4:34 AM , Osmany Goderich Navarro <osmany at oc.quimefa.cu> wrote:

> utility that's built in AD and it works fine. I can specifically extract de
> OU of my interest but the problem is that the users in the output file come
> out with lots of attributes that are not compatible with the samba
> schema. I'm wondering if there is some script that can restructure and modify
> the users so that I can import these users to OpenLDAP with a simple ldapadd
> command.

There aren't any that I'm personally aware of (maybe others on the list know of
scripts that I don't know about), but once you have an LDIF it's all text. You
could slap a Perl or Python script together in no time; these scripts tend to
be very site-specific.  

The Windows 2003 'R2' LDAP schema for AD is RFC 2307 compliant, so if your
target LDAP directory is RFC 2307, it should be a piece of cake.  Either you
add the necessary AD attributes to your LDAP schema, or you simply weed the
ones you don't care about out of the of the LDIF by using something along the
lines of what 'grep -v' does.

If you're using some other ActiveDirectory schema, I'm afraid it's going to be
rather harder.

Message sent via Atmail Open - http://atmail.org/

More information about the samba mailing list