Add /etc/group to openldap
My environment: CentOS4.2, Samba + openldap
I was doing below procedure to add the /etc/group to LDAP but fail:
[root@web migration]# cp /etc/group /root/group
[root@web migration]# ./migrate_group.pl /root/group > /root/group.ldif
[root@web migration]# ldapadd -x -D "cn=root,dc=wilson,dc=com" -W -f /root/group.ldif
Enter LDAP Password
adding new entry "cn=teachers,ou=Group,dc=wilson,dc=com"
ldap_add: No such object (32)
matched DN: dc=wilson,dc=com
passwd.ldif info:
dn: cn=teachers,ou=Group,dc=wilson,dc=com
objectClass: posixGroup
objectClass: top
cn: teachers
userPassword: {crypt}x
gidNumber: 521
memberUid: 521
dn: cn=students,ou=Group,dc=wilson,dc=com
objectClass: posixGroup
objectClass: top
cn: students
userPassword: {crypt}x
gidNumber: 522
memberUid: 522
ldapsearch -x -b 'dc=wilson,dc=com'
...................................
....................................
....................................
# Groups, wilson.com
dn: ou=Groups,dc=wilson,dc=com
ou: Groups
objectClass: organizationalUnit
...........................................
.........................................
......................................
I don't know where to be wrong
Thanks !!
|