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

Re: can't ldapadd



Make sure that there are no trailing spaces at the end of your entries in the ldif file.



Michael Fairchild said:
> Hello,
>   I am trying to get openldap runnig, but whenever i try and add some
> entries (the test entries from the quickstart guide for now) I get the result:
> -----------------
> adding new entry "dc=example,dc=com "
> ldap_add: Invalid syntax
>         additional info: objectclass: value #0 invalid per syntax
> ldif_record() = 21
> -----------------
>
> I am running gentoo linux with openldap-2.0.25. my slapd.conf file: ------------
> include         /etc/openldap/schema/core.schema
> pidfile         /var/state/openldap/slapd.pid
> argsfile        /var/state/openldap/slapd.args
> database ldbm
> suffix "dc=example,dc=com"
> rootdn "cn=Manager,dc=example,dc=com"
> rootpw secret
> directory /var/state/openldap/openldap-ldbm
> index   objectClass     eq
> ----------
>
> I tried setting the directory to 777 permissions and the dn2id.dbb file with no change.
>
> When I try this with "slapd -d 1" running i see get:
> -----------------
> slapd starting
> connection_get(9): got connid=0
> connection_read(9): checking for input on id=0
> ber_get_next
> ber_get_next: tag 0x30 len 46 contents:
> ber_get_next
> ber_get_next on fd 9 failed errno=11 (Resource temporarily unavailable) do_bind
> ber_scanf fmt ({iat) ber:
> ber_scanf fmt (o}) ber:
> do_bind: version=3 dn="cn=Manager,dc=example,dc=com" method=128
> dn2entry_r: dn: "CN=MANAGER,DC=EXAMPLE,DC=COM"
> => dn2id( "CN=MANAGER,DC=EXAMPLE,DC=COM" )
> => ldbm_cache_open( "dn2id.dbb", 73, 600 )
> <= ldbm_cache_open (opened 0)
> <= dn2id NOID
> dn2entry_r: dn: "DC=EXAMPLE,DC=COM"
> => dn2id( "DC=EXAMPLE,DC=COM" )
> => ldbm_cache_open( "dn2id.dbb", 73, 600 )
> <= ldbm_cache_open (cache 0)
> <= dn2id NOID
> do_bind: v3 bind: "cn=Manager,dc=example,dc=com" to
> "cn=Manager,dc=example,dc=com"
> send_ldap_result: conn=0 op=0 p=3
> send_ldap_response: msgid=1 tag=97 err=0
> ber_flush: 14 bytes to sd 9
> connection_get(9): got connid=0
> connection_read(9): checking for input on id=0
> ber_get_next
> ber_get_next: tag 0x30 len 113 contents:
> deferring operation
> ber_get_next
> ber_get_next on fd 9 failed errno=11 (Resource temporarily unavailable) do_add
> ber_scanf fmt ({a) ber:
> ber_scanf fmt ({a{V}}) ber:
> ber_scanf fmt ({a{V}}) ber:
> ber_scanf fmt ({a{V}}) ber:
> ber_scanf fmt (}) ber:
> dn2entry_r: dn: "DC=EXAMPLE,DC=COM"
> => dn2id( "DC=EXAMPLE,DC=COM" )
> => ldbm_cache_open( "dn2id.dbb", 73, 600 )
> <= ldbm_cache_open (cache 0)
> <= dn2id NOID
> send_ldap_result: conn=0 op=1 p=3
> send_ldap_response: msgid=2 tag=105 err=21
> ber_flush: 54 bytes to sd 9
> connection_get(9): got connid=0
> connection_read(9): checking for input on id=0
> ber_get_next
> ber_get_next: tag 0x30 len 5 contents:
> ber_get_next
> ber_get_next on fd 9 failed errno=0 (Success)
> connection_read(9): input error=-2 id=0, closing.
> connection_closing: readying conn=0 sd=9 for close
> connection_close: deferring conn=0 sd=9
> do_unbind
> connection_resched: attempting closing conn=0 sd=9
> connection_close: deferring conn=0 sd=9
> connection_resched: attempting closing conn=0 sd=9
> connection_close: conn=0 sd=9
> ------------
>
> sorry for the big debug output, but I wasn't sure what to cut out. I thought it was strange that the ldbm_cache_open
> call did not display a full path. At first I thought this was the problem, that it wasn't finding the dn2id.dbb
> file, but now I don't think so since the file is indeed getting created.
> Any ideas would be greatly appreciated.
> Thanks,
> Michael Fairchild
>
> __________________________________________________
> Do you Yahoo!?
> Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
> http://mailplus.yahoo.com


-- 
Jeff Greer
Technical Support Consultant
Fretwell-Downing, Inc.
Phone: (913) 239-1214

The information transmitted in this electronic mail message may contain
confidential and or privileged materials.  For full details and restrictions
see http://www.fdgroup.com/emaildisclaimer.html