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

Re: ldap problem



hi
    i m veri new to ldap, in my config file i hav line

rootdn "cn=Manager,dc=linux,dc=lin"

so in ldapadd command when i give

./ldapadd -f /tmp/test.txt -D rootdn -W
Enter LDAP Password: 
ldap_bind: Invalid DN syntax (34)
        additional info: invalid DN

i mean from my config file i m creating a new dn entry
so do i need to mention -D option ?

dn: cn=Manish,dc=linux,dc=lin
objectClass: person
cn: Manish
sn: Arya
mail: mkarya@rainbow.com
uid: mkarya

Ahhhhhhhhhhh..........I am all confused
I am going for tea break please help !!!!!!!!

-Manish
LinuxIndia.net
--- Pierangelo Masarati <ando@sys-net.it> wrote:
> 
> > hi
> > i am using openldap 2.2.8
> > here is my slapd.conf file
> >
> >
>
-----------------------------------------------------
> > include
> > /shared/openldap-/etc/openldap/schema/core.schema
> >
> > pidfile /shared/openldap-/var/run/slapd.pid
> > argsfile /shared/openldap-/var/run/slapd.args
> >
>
#######################################################################
> > # ldbm database definitions
> >
>
#######################################################################
> >
> > database bdb
> > suffix "dc=linux,dc=lin"
> > rootdn "cn=Manager,dc=linux,dc=lin"
> > # Cleartext passwords, especially for the rootdn,
> > should
> > # be avoid. See slappasswd( and slapd.conf(5) for
> > details.
> > # Use of strong authentication encouraged.
> > rootpw secret
> > #rootpw {CRYPT}ZPXImACgFFnW6
> > # The database directory MUST exist prior to
> running
> > slapd AND
> > # should only be accessible by the slapd and slap
> > tools.
> > # Mode 700 recommended.
> > directory /shared/openldap-/var/openldap-data
> > # Indices to maintain
> > index objectClass eq
> > -----------------------------------------
> >
> > and here is my ldap.conf file
> > #
> > # LDAP Defaults
> > #
> >
> > # See ldap.conf(5) for details
> > # This file should be world readable but not world
> > writable.
> >
> > BASE dc=linux dc=lin
> > URI ldap:// ldaps://
> >
> > #SIZELIMIT 12
> > #TIMELIMIT 15
> > #DEREF never
> > ---------------------------------------
> >
> > i m staring ldap like this
> > .........................................
> > $libexec/slapd -d
> > entifierMatch' APPLIES (
> supportedApplicationContext $
> > supportedFeatures $ supportedExtension $
> > supportedControl ) )
> > slapd startup: initiated.
> > bdb_db_open:
> > dbenv_open(/shared/openldap-/var/openldap-data)
> > slapd starting
> > -----------------------------------------------
> >
> > then when i add some user from a file
> > [root@linux openldap]# cat /tmp/test.txt
> > dn: cn=Manish,dc=linux,dc=lin
> > objectClass: person
> > cn: Manish
> > sn: Arya
> > title: danger ahead.....don't move
> > mail: mkarya@rainbow.com
> > uid: mkarya
> >
> >
> > like
> > $./ldapadd -f /tmp/test.txt -W
> >
> > i get error
> > [root@linux bin]# ./ldapadd -f /tmp/test.txt -W
> > Enter LDAP Password:
> > ldap_bind: Invalid credentials (49)
> >
> > and on xterm running ldap i get
> >
> >
> > connection_read(10): checking for input on id=0
> > ber_get_next
> > ber_get_next: tag 0x30 len 18 contents:
> > ber_get_next
> > ber_get_next on fd 10 failed errno=11 (Resource
> > temporarily unavailable)
> > do_bind
> > ber_scanf fmt ({imt) ber:
> > ber_scanf fmt (m}) ber:
> >>>> dnPrettyNormal: <>
> > <<< dnPrettyNormal: <>, <>
> > do_bind: version=3 dn="" method=128
> 
>                      ^^^^^
> 
> you're not supplying any bind DN, so your
> authentication is invalid.
> read about switch -D for ldap tools (e.g. man
> ldapadd(1)).
> 
> p.
> 
> -- 
> Pierangelo Masarati
> mailto:pierangelo.masarati@sys-net.it
> 
> 



	
		
__________________________________
Do you Yahoo!?
Yahoo! Tax Center - File online by April 15th
http://taxes.yahoo.com/filing.html