openldap ldap_bind: Invalid credentials (49)
I was trying to learn OpenLdap on Ubuntu 9.04.
Code:
# slapd.conf - Configuration file for LDAP SLAPD Code:
# This file should be world readable but not world writable. then I tested my configuration using Code:
sudo slaptest -v -f slapd.conf Then I restared openldap server using Code:
sudo invoke-rc.d slapd restart Then I tried followng command Code:
ldapsearch -x -W -D 'cn=Manager,dc=example,dc=com' -b "" -s base I get following prompt Enter LDAP Password: I entered secret but I get following error ldap_bind: Invalid credentials (49) Please help |
use the slappasswd tool to get an encrypted password and replace the plaintext one with that, e.g. "rootpw {SSHA}W0CjkdAxj7ziBcG37+Bog2zf1bIf2GrA"
|
I tried not working
{SSHA}EN3+ZmSaaZSb5ndB9FlDLzs+fM2Sc2lL |
what does the server log say about the attempt?
|
Well thanks for trying to help.
I tried to look into /var/log/syslog. But I could not find anything useful with respect to slapd. So I tried something different. I killed process using Code:
sudo kill `pgrep slapd` Code:
sudo slapd -d Trace After I entered following search command in second shell Code:
ldapsearch -x -W -D 'cn=Manager,dc=example,dc=com' -b "" -s base Code:
slapd startup: initiated. |
where is dc=nodomain coming from? I'm not that used to slapd logs, but there's no reference to loading your "example" domain at all... are you configuring the wrong slapd.conf file or something like that?
btw, afaik slapd should log to /var/log/ldap.log or similar. |
I exactly had same doubt.
I searched sudo find / -name 'slapd.conf' and I got only one which I am using. /etc/ldap/slapd.conf |
I did it :-)
sudo slapd -f /etc/ldap/slapd.conf -d config with -f option, I specified file and it worked. I doubt it could not find my configuration file slapd.conf, so it started server with default configuration. But when I provided file with -f option, it worked. Thank you very much for help. |
I have exactly the same problem however I could not solve the problem. Plz sanjaydelhi if you can spare sometime then kindly help me out how to resolve this.
Cheers, |
Oh I came to LQ after long time.
Right now I am not doing r&d on OpenLDAP. But I installed OpenLDAP on Ubuntu 10.10 mulitple times and run it with the method I just described above. In Ubuntu 10.10 after installing OpenLDAP through package installer, you will have to manually add few files in your OpenLDAP installation on Ubuntu 10.10. The location of the files you will have to find out because I have forgotten now. Otherwise install OpenLDAP on Ubuntu 9.04. It works okay in Ubuntu 9.04. Good luck. [Edit] I tried to attach file, but looks like zip files are not allowed, so I will write names of those files here id2entry.bdb dn2id.bdb DB_CONFIG Note that I did not find OpenLDAP document sufficient. |
All times are GMT -5. The time now is 10:36 PM. |