[Date Prev][Date Next] [Chronological] [Thread] [Top]


when am trying to add ldapuser.ldif am getting this error.

[root@server ~]# ldapadd -x -D "cn=Manager,dc=example,dc=com" -W -f /etc/openldap/ldapusers.ldif
Enter LDAP Password:
adding new entry "uid=ldapuser,ou=People,cn=Manager,dc=example,dc=com"
ldap_add: No such object (32)
        matched DN: cn=Manager,dc=example,dc=com


This is my ldapuser.ldif

dn: uid=ldapuser,ou=People,cn=Manager,dc=example,dc=com
uid: ldapuser
cn: Manager
ou: People
objectClass: account
objectClass: posixAccount
objectClass: top
objectClass: shadowAccount
userPassword: {crypt}c3ZWmT7fM2thY
shadowLastChange: 13927
shadowMax: 99999
shadowWarning: 7
loginShell: /bin/bash
uidNumber: 507
gidNumber: 100
homeDirectory: /home/ldapuser

And is it necessary to extract the information of ldapuser from /etc/passwd file and for
linux root account and extracted the /etc/passwd data into an ldif file and imported to
that database.