2013-03-22 4 views
7

실행 중 OpenLDAP 2.4-28XUBUNTU 12.04.ldap_bind : 유효하지 않은 자격증 명 (49)

나는 "마스터 링 OpenLDAP"을 읽고 책과 함께 구성 중입니다.

$ ldapsearch -x -W -D 'cn=Manager,dc=example,dc=com' -b "" -s base 

내가 암호를 입력하라는 메시지입니다 :

난 다음 검색 (47 페이지)를 수행하려고

. 그럼 난 "비밀"를 입력하지만 다음과 같은 오류 얻을 : 다음은

ldap_bind: Invalid Credentials (49). 

입니다 내 slapd.conf :

# slapd.conf - Configuration file for LDAP SLAPD 
########## 
# Basics # 
########## 
include /etc/ldap/schema/core.schema 
include /etc/ldap/schema/cosine.schema 
include /etc/ldap/schema/inetorgperson.schema 
pidfile /var/run/slapd/slapd.pid 
argsfile /var/run/slapd/slapd.args 
loglevel none 
modulepath /usr/lib/ldap 
# modulepath /usr/local/libexec/openldap 
moduleload back_hdb 

########################## 
# Database Configuration # 
########################## 
database hdb 
suffix "dc=example,dc=com" 
rootdn "cn=Manager,dc=example,dc=com" 
rootpw secret 
directory /var/lib/ldap 
# directory /usr/local/var/openldap-data 
index objectClass,cn eq 

######## 
# ACLs # 
######## 
access to attrs=userPassword 
    by anonymous auth 
    by self write 
    by * none 
access to * 
    by self write 
    by * none 

여기에 ldap.conf입니다 :

# LDAP Client Settings 
URI ldap://localhost 
BASE dc=example,dc=com 
BINDDN cn=Manager,dc=example,dc=com 
SIZELIMIT 0 
TIMELIMIT 0 

안부가 알리 Reza

+0

다소 관련 : http://wiki.openiam.com/pages/viewpage.action?pageId=7635198 – cregox

+0

@alibaba에 대한 답변을 찾으셨습니까? 같은 오류가 발생합니다. – Matt

답변

10

나는 명백한 문제를 보지 못한다. 비둘기.

이 가능 ldap.conf이 무시되고 있지만, 명령 줄 옵션이 ldapsearchldap.confBINDDN을 무시합니다, 우선, 그래서 잘못 될 수있는 유일한 매개 변수는 URI 당신의. (순서는이 환경 변수도이 영향을 미칠 수 있지만, man ldapconf를 참조 ETCDIR/ldap.conf 다음 ~/ldaprc 또는 ~/.ldaprc현재 디렉토리에 다음 ldaprc입니다.)

시도 명시 적 URI :

ldapsearch -x -W -D 'cn=Manager,dc=example,dc=com' -b "" -s base -H ldap://localhost 

또는 다음을 사용하여 기본값을 방지합니다.

LDAPNOINIT=1 ldapsearch -x -W -D 'cn=Manager,dc=example,dc=com' -b "" -s base 

그래도 작동하지 않으면 일부 문제가 발생합니다. eshooting (당신은이에 대한 slapd 바이너리의 전체 경로가 필요 아마거야)

  • 것이 확인하여 slapd.conf 사용하고 루트로 정확하고 있습니다

    slapd -T test -f slapd.conf -d 65535

    당신 수도 왼쪽 또는 기본값이 slapd.d구성 디렉토리가이고 사용자의 slapd.conf보다 우선합니다 (명시 적으로 구성을 -f으로 지정하지 않으면 slapd.conf이 공식적으로 dep입니다). OpenLDAP-2.4에서 인용). 여러 페이지의 출력을 얻지 못하면 바이너리가 으로 빌드되어 디버그가 지원되지 않습니다.

  • 정지 OpenLDAP를, 수동 ((종료 루트로,^C)를 활성화 디버그와 별도의 터미널/콘솔

    slapd -h ldap://localhost -d 481

    다음 검색을 다시 시도하고 문제를 발견 할 수 있는지에 slapd 시작 불행히도 출력 초기에는 많은 스키마 노이즈가있을 것입니다.) (참고 : -u/-g 옵션없이 slapd을 실행하면 문제가 발생할 수 있습니다 파일 소유권을 변경할 수 있습니다, 당신은 일반적으로 이러한 옵션을 사용한다 아마-u ldap -g ldap를)

  • 를 디버그가 활성화 된 경우, 다음

    ldapsearch -v -d 63 -W -D 'cn=Manager,dc=example,dc=com' -b "" -s base

  • 도 시도
관련 문제