코멘트 달아주신 분...고맙슴다..
근데 하나 더 물어봐도 될른지....?
데몬 하나 떠있는것이 별 문제 되지 않는다면 왜 ldapadd가 되지 않는지 몰겠슴다..
slapd.conf파일은 다음과 같구요
# $OpenLDAP: pkg/ldap/servers/slapd/slapd.conf,v 1.23.2.8 2003/05/24 23:19:14 kurt Exp $
#
# See slapd.conf(5) for details on configuration options.
# This file should NOT be world readable.
#
include /usr/local/etc/openldap/schema/core.schema
include /usr/local/etc/openldap/schema/cosine.schema
include /usr/local/etc/openldap/schema/inetorgperson.schema
include /usr/local/etc/openldap/schema/nis.schema
# Define global ACLs to disable default read access.
# Do not enable referrals until AFTER you have a working directory
# service AND an understanding of referrals.
#referral ldap://root.openldap.org
pidfile /usr/local/var/slapd.pid
argsfile /usr/local/var/slapd.args
# Load dynamic backend modules:
# modulepath /usr/local/libexec/openldap
# moduleload back_bdb.la
# moduleload back_ldap.la
# moduleload back_ldbm.la
# moduleload back_passwd.la
# moduleload back_shell.la
# Sample security restrictions
# Require integrity protection (prevent hijacking)
# Require 112-bit (3DES or better) encryption for updates
# Require 63-bit encryption for simple bind
# security ssf=1 update_ssf=112 simple_bind=64
# Sample access control policy:
# Root DSE: allow anyone to read it
# Subschema (sub)entry DSE: allow anyone to read it
# Other DSEs:
# Allow self write access
# Allow authenticated users read access
# Allow anonymous users to authenticate
# Directives needed to implement policy:
# access to dn.base="" by * read
# access to dn.base="cn=Subschema" by * read
# access to *
# by self write
# by users read
# by anonymous auth
#
# if no access controls are present, the default policy is:
# Allow read by all
#
# rootdn can always write!
#######################################################################
# ldbm database definitions
#######################################################################
database bdb
suffix "dc=my-domain,dc=com"
rootdn "cn=Manager,dc=my-domain,dc=com"
# Cleartext passwords, especially for the rootdn, should
# be avoid. See slappasswd(8) and slapd.conf(5) for details.
# Use of strong authentication encouraged.
rootpw secret
# The database directory MUST exist prior to running slapd AND
# should only be accessible by the slapd and slap tools.
# Mode 700 recommended.
directory /usr/local/var/openldap-data
# Indices to maintain
index objectClass eq
#index cn,sn,uid pres,eq,approx,sub
#index objectClass,uid,uidNumber,gidNumber,memberUid eq
#index cn,mail,surname,givenname eq,subinitial
원인을 잘 몰라서 인덱스에서 주석처리 된 부분을 더 집어넣어봤구요
인클루드에 몇가지를 더 집어넣었습니다...
암튼 설정파일은 위와 같구요
다음과 같이 ldif파일 만들어서 그 아래와 같이 명령줄에서 실행했슴다
<test.ldif>
dn: dc=my-domain,dc=com
objectClass: dcObject
objectClass: organization
o: zozig
dc: private
dn: cn=test,dc=my-domain,dc=com
objectClass: organizationalRole
cn: Test
<end of test.ldif>
#/usr/local/libexec/slapd -f /usr/local/etc/openldap/slapd.conf (데몬실행)
#/usr/local/bin/ldapadd -x -h 123.345.567.789 -D "cn=Manager,dc=my-domain,dc=com" -w secret -f test.ldif (엔트리 추가)
adding new entry "dc=my-domain,dc=com" <----여기부터 에러메시지
ldapadd: update failed: dc=my-domain,dc=com
ldap_add: Naming violation (64)
additional info: value of naming attribute 'dc' is not present in entry <---에러메시지 끝
요로코롬 나옴다...
제가 알기로는 dcObject에은 dc라는 어트리뷰트가 있는걸루 알구 있는데 왜 이런 에러가 나는지..
엔트리를 못넣으니깐 접속은 되도 리스트를 불러오지 못하니 원~~
귀찮으시더라두 도움될만한 힌트를 주시면 감사하겠슴다..
thanks in advance...
|