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

result 32: no such object



Can someone clue me in to why I can add entries to my LDAP database, and dump them with slapcat, but I can't search them?

This is my LDIF input:

	dn: dc=avtechpulse,dc=com
	dc: avtechpulse
	objectClass: dcObject
	objectClass: organizationalUnit
	ou: Avtech

	dn: ou=People,dc=avtechpulse,dc=com
	ou: People
	objectClass: organizationalUnit

	dn: uid=mjc,ou=People,dc=avtechpulse,dc=com
	uid: mjc
	objectClass: account

Which is added successfully:
	
	slapadd -v -l ldap6
	added: "dc=avtechpulse,dc=com" (00000001)
	added: "ou=People,dc=avtechpulse,dc=com" (00000002)
	added: "uid=mjc,ou=People,dc=avtechpulse,dc=com" (00000003)

But searching on it fails!

	ldapsearch -v -x -D "cn=ldapadmin,ou=users,dc=avtechpulse,dc=com" -w 
	"notarealpassword" -b "dc=avtechpulse,dc=com"

	ldap_initialize( <DEFAULT> )
	filter: (objectclass=*)
	requesting: ALL
	# extended LDIF
	#
	# LDAPv3
	# base <dc=avtechpulse,dc=com> with scope sub
	# filter: (objectclass=*)
	# requesting: ALL
	#

	# search result
	search: 2
	result: 32 No such object

	# numResponses: 1


Am I doing anything obviously wrong?


This is my slapd.conf file:

# $OpenLDAP: pkg/ldap/servers/slapd/slapd.conf,v 1.8.8.7 2001/09/27 20:00:31 kurt Exp $
#
# See slapd.conf(5) for details on configuration options.
# This file should NOT be world readable.
#
include		/etc/openldap/schema/core.schema
include		/etc/openldap/schema/misc.schema
include		/etc/openldap/schema/cosine.schema
include		/etc/openldap/schema/inetorgperson.schema
include		/etc/openldap/schema/nis.schema
#include		/etc/openldap/schema/redhat/rfc822-MailMember.schema
include		/etc/openldap/schema/redhat/autofs.schema
#include		/etc/openldap/schema/redhat/kerberosobject.schema
#include		/usr/share/evolution/evolutionperson.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

loglevel	296
pidfile		/var/run/slapd.pid
argsfile	/var/run/slapd.args

# Create a replication log in /var/lib/ldap for use by slurpd.
#replogfile	/var/lib/ldap/master-slapd.replog

# Load dynamic backend modules:
# modulepath	/usr/sbin/openldap
# moduleload	back_ldap.la
# moduleload	back_ldbm.la
# moduleload	back_passwd.la
# moduleload	back_shell.la

#
# The next three lines allow use of TLS for connections using a dummy test
# certificate, but you should generate a proper certificate by changing to
# /usr/share/ssl/certs, running "make slapd.pem", and fixing permissions on
# slapd.pem so that the ldap user or group can read it.
# TLSCertificateFile /usr/share/ssl/certs/slapd.pem
# TLSCertificateKeyFile /usr/share/ssl/certs/slapd.pem
# TLSCACertificateFile /usr/share/ssl/certs/ca-bundle.crt
#
# Sample Access Control
#	Allow read access of root DSE
#	Allow self write access
#	Allow authenticated users read access
#	Allow anonymous users to authenticate
#
access to attrs=userPassword
	by self write
	by * compare

access to dn="ou=people,dc=avtechpulse,dc=com" 
	by self write
	by * read

access to dn="ou=(.+),ou=contacts,dc=avtechpulse,dc=com"
	by dn="uid=$1,ou=people,dc=avtechpulse,dc=com" write
	by * none

access to *
	by * read


# if no access controls are present, the default is:
#	Allow read by all
#
# rootdn can always write!

#######################################################################
# ldbm database definitions
#######################################################################

database	ldbm
suffix		"dc=avtechpulse,dc=com"

rootdn		"cn=ldapadmin,ou=users,dc=avtechpulse,dc=com"
# Cleartext passwords, especially for the rootdn, should
# be avoided.  See slappasswd(8) and slapd.conf(5) for details.
# Use of strong authentication encouraged.
rootpw		notarealpassword


# The database directory MUST exist prior to running slapd AND 
# should only be accessible by the slapd/tools. Mode 700 recommended.
directory	/var/lib/ldap

# Indices to maintain
index	objectClass,uid,uidNumber,gidNumber,memberUid	eq
index	cn,mail,surname,givenname			eq,subinitial

# Replicas to which we should propagate changes
#replica host=ldap-1.example.com:389 tls=yes
#	bindmethod=sasl saslmech=GSSAPI
#	authcId=host/ldap-master.example.com@EXAMPLE.COM