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

Re: Why can't I add entries???



At first, it displays that:
[root@NsfcServer openldap]# ldapadd -x -D "cn=root,o=Acme,c=US" -W -f /home/xdw/
testdata.ldif
Enter LDAP Password:
adding new entry "o=Acme,c=US"
I think it is successful, So I use command 'ldapsearch' and software 'ldapBE' to search entry, But only the 'o=Acme,c=US' matched!! The rest entries of testdata.ldif was not be added!!!


And I want to add again, it displays that :
[root@NsfcServer openldap]# ldapadd -x -D "cn=root,o=Acme,c=US" -W -f /home/xdw/
testdata.ldif
Enter LDAP Password:
adding new entry "o=Acme,c=US"
ldap_add: Already exists


ldif_record() = 68

So, I want to delete the entry and readd it!!
[root@NsfcServer openldap]# ldapdelete -x "cn=root,o=Acme,c=US"
Delete Result: No such object (32)
Matched DN: o=Acme,c=US

But, I use ldapsearch it display:
[root@NsfcServer openldap]# ldapsearch -x -b 'cn=root,o=Acme,c=US' '(objectClass
=*)'
version: 2


#
# filter: (objectClass=*)
# requesting: ALL
#

# search result
search: 2
result: 32 No such object
matchedDN: o=Acme,c=US

# numResponses: 1

Can you solve the problem?
Please help me!!
Thank you!!

From: Jatin Nansi <jatin.nansi@timesgroup.com>
Reply-To: jatin.nansi@timesgroup.com
To: "David Hsu" <ldaplearner@hotmail.com>, openldap-software@OpenLDAP.org
Subject: Re: Why I can't add entries???
Date: Sat, 6 Apr 2002 15:08:41 +0530

OK, so what error does ldapadd give?

Jatin

On Saturday 06 April 2002 13:57, David Hsu wrote:
> Hello everyone, I'm running openldap-2.0.23 on Redhat Linux 7.2.
> But when I add entry to my db, I've just encountered the problem:
> Only the 'dn:o=Acme,c=US' has been added successfully and the others
> failed. My slapd.conf and testdata.ldif are as follows:
>
> 1 slapd.conf
> .............
> include	       /usr/local/etc/openldap/schema/core.schema
> include         /usr/local/etc/openldap/schema/corba.schema
> include         /usr/local/etc/openldap/schema/cosine.schema
> include         /usr/local/etc/openldap/schema/inetorgperson.schema
> include         /usr/local/etc/openldap/schema/java.schema
> include         /usr/local/etc/openldap/schema/krb5-kdc.schema
> include         /usr/local/etc/openldap/schema/misc.schema
> include         /usr/local/etc/openldap/schema/nis.schema
> include         /usr/local/etc/openldap/schema/openldap.schema
> ......
> pidfile		/usr/local/var/slapd.pid
> argsfile	/usr/local/var/slapd.args
> ..................
> #######################################################################
> # ldbm database definitions
> #######################################################################
>
> database	ldbm
> #suffix		"dc=my-domain,dc=com"
> suffix		"o=Acme,c=US"
> #rootdn		"cn=Manager,dc=my-domain,dc=com"
> rootdn		"cn=root,o=Acme,c=US"
> ..................
> rootpw		xjtu
> ..................
> directory	/usr/local/var/openldap-ldbm
> ..................
> index	objectClass	eq
>
> 2 testdata.ldif
> #AcmeDN
> dn:o=Acme,c=US
> objectClass:organization
> o:Acme
>
> #ManagersDN
> dn:ou=Managers,o=Acme,c=US
> objectClass:organizationalUnit
> ou:Managers
>
> #FirstManagerDn
> dn:cn=Jason H. Smith,ou=Managers,o=Acme,c=US
> objectClass:inetOrgPerson
> cn:Jason H. Smith
> sn:Smith
> telephoneNumber:111-222-9999
> mail:headhauncho@acme.com
>
> #EmployeesDN
> dn:ou=Employee,o=Acme,c=US
> objectClass:organizationalUnit
> ou:Employees
>
> #FirstEmployeeDN
> dn:cn=Ray D. Jones,ou=Employees,o=Acme,c=US
> objectClass:inetOrgPerson
> cn:Ray D. Jones
> sn:Jones
> telephoneNumber:444-555-8888
> mail:jonesrd@acme.com
> localityName:Houston
>
> #SecondEmployeeDN
> dn:cn=Eric S. Woods,ou=Employees,o=Acme,c=US
> objectClass:inetOrgPerson
> cn:Eric S. Woods
> sn:Woods
> telephoneNumber:444-555-6666
> mail:woodses@acme.com
> localityName:Houston
>
> How can I solve the problem!!!
> Please lend me a hand!!
> Thanks in advance!!
>
> David Hsu
> Ph.D
> Computer Science
> Xi'an Jiaotong University
> Xi'an China
>
>
> _________________________________________________________________
> MSN Photos is the easiest way to share and print your photos:
> http://photos.msn.com/support/worldwide.aspx




David Hsu
Ph.D
Computer Science
Xi'an Jiaotong University
Xi'an China


_________________________________________________________________
MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx