免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
楼主: py
打印 上一主题 下一主题

[ldap] 写给所有OpenLDAP不能正常启动的人 [复制链接]

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
101 [报告]
发表于 2006-11-17 20:02 |只看该作者
原帖由 windychan 于 2006-11-17 15:54 发表
用: /usr/local/libexec/slapd -u ldap -d -1 看到.如下

..............
backend_startup_one: starting "dc=beltontech,dc=com"
bdb_db_open: dc=beltontech,dc=com
bdb_db_open: Wa ...

显示一般的错误或调试的时候用-d256足以
这个提示我记得好像是2.2.*以后有的, DB_CONFIG文件中写入的是bdb的一些优化参数,默认安装openldap在这里会有以个example file, /usr/local/etc/openldap/DB_CONFIG.example
把这个文件改名后放到/usr/local/var/openldap-data下就可以了

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
102 [报告]
发表于 2006-11-17 20:12 |只看该作者
原帖由 wenhong3000 于 2006-11-17 16:09 发表
我安装好openldap后,不能对person添加email属性,在schema中把email属性添加进去后,openldap就不能启动了,请问是什么回事,非常感谢

person太接近top了, 在schema中person的MAY中的属性很少
在用户的objectclass属性中加上inetOrgPerson, 或包含mail属性的objectclass

论坛徽章:
0
103 [报告]
发表于 2006-12-25 14:34 |只看该作者

请帮忙看看如下问题

./slapd -d 256启动slapd后,显示如下,请问都有哪些问题?
================================================
@(#) $OpenLDAP: slapd 2.3.27 (Dec 12 2006 10:35:02) $
        root@localhost.localdomain:/root/testproject/ldap/openldap-2.3.27/servers/slapd
daemon: IPv6 socket() failed errno=97 (Address family not supported by
protocol)bdb_db_open: unclean shutdown detected; attempting recovery.
bdb_db_open: Warning - No DB_CONFIG file found in directory
/usr/local/openldap/var/openldap-data: (2)
Expect poor performance for suffix dc=nari-china,dc=com.
slapd starting

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
104 [报告]
发表于 2006-12-25 18:27 |只看该作者
编译的时候可以把IPv6 disable掉就不会有相关问题了.
你的db没有正常退出, 或出现了数据问题, 2.3.x会尝试用dbrecovery恢复.
DB_CONFIG file是用来优化数据库的, 这个文件应该放在/usr/local/openldap/var/openldap-data这个目录.

论坛徽章:
0
105 [报告]
发表于 2006-12-26 09:47 |只看该作者

回复 102楼 py 的帖子

好多多谢,我试一试!!

论坛徽章:
0
106 [报告]
发表于 2006-12-26 10:46 |只看该作者

请教slapd.conf的配置

我用的是OPENLDAP2.3.27, 我运行下面的命令是提示照不到文件:"/usr/local/openldap/var/openldap-data/id2entry.bdb",但是我仔细检查了,这个文件是存在的,请教这知道是什么原因? 哪个知道是什么原因,请指教一下,非常感激!

[root@localhost libexec]# ./slapd -d 256
@(#) $OpenLDAP: slapd 2.3.27 (Dec 22 2006 11:06:46) $
        root@localhost.localdomain:/root/openldap-2.3.27/servers/slapd
bdb_db_open: db_open(/usr/local/openldap/var/openldap-data/id2entry.bdb) failed: No such file or directory (2)
bdb(dc=example,dc=com): Unknown locker ID: 0
backend_startup_one: bi_db_open failed! (2)
bdb_db_close: alock_close failed
slapd stopped.
connections_destroy: nothing to destroy.

论坛徽章:
0
107 [报告]
发表于 2006-12-26 10:54 |只看该作者

您好,在ldapadd一个ldif文件时,出现如下错误:

您好,在ldapadd一个ldif文件时,请问出现如下错误原因(google上没有搜索到):
=====================================
adding new entry "dc=info,dc=com"
ldap_add: DSA is unwilling to perform
        additional info: no global superior knowledge

ldif_record() = 53
=====================================
谢谢!!!

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
108 [报告]
发表于 2006-12-26 17:30 |只看该作者
原帖由 wubm 于 2006-12-26 10:46 发表
我用的是OPENLDAP2.3.27, 我运行下面的命令是提示照不到文件:"/usr/local/openldap/var/openldap-data/id2entry.bdb",但是我仔细检查了,这个文件是存在的,请教这知道是什么原因? 哪个知道是什么原因,请 ...

是第一次启动就这样提示吗?
安装openldap的时候,make test都成功了吗?
配置文件时候有做过什么改动?
从错误提示上看就是指定的文件不存在.

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
109 [报告]
发表于 2006-12-26 17:36 |只看该作者
原帖由 yalechen 于 2006-12-26 10:54 发表
您好,在ldapadd一个ldif文件时,请问出现如下错误原因(google上没有搜索到):
=====================================
adding new entry "dc=info,dc=com"
...

非启动问题还是开个新贴吧.
另外, 最好把相关的情况写清楚,slapd.conf文件的内容?ldif文件的内容?..

论坛徽章:
0
110 [报告]
发表于 2006-12-28 16:06 |只看该作者
斑竹你好 询问一下  ldap启动是由这种报错 [root@dkhmain openldap]# /usr/local/libexec/slapd -d 256
bdb_initialize: Sleepycat Software: Berkeley DB 4.2.52: (December  3, 2003)
/usr/local/etc/openldap/schema/aquarius.schema: line 12: unknown directive "Attributes" outside backend info and database definitions (ignored)
bdb_db_init: Initializing BDB database
bdb(dc=eastcom-ca,dc=com): Program version 4.2 doesn't match environment version
bdb_db_open: dbenv_open failed: Invalid argument (22)
backend_startup: bi_db_open(0) failed! (22)
bdb(dc=eastcom-ca,dc=com): txn_checkpoint interface requires an environment configured for the transaction subsystem
bdb_db_destroy: txn_checkpoint failed: Invalid argument (22)
slapd stopped.
connections_destroy: nothing to destroy.我的sladp。conf是这样的 nclude         /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/aquarius.schema
include         /usr/local/etc/openldap/schema/java.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.

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
#
#   Disallow clear text exchange of passwords
# disallow bind_simple_unprotected
#
#       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!

access to attr=userpassword
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by self write
        by anonymous auth


access to filter="(OpenLDAPaci=*EVERYONE*)"
        by users write

access to dn.base="dc=eastcom-ca,dc=com"
        by users read

access to dn.base="ou=handler,dc=eastscom-ca, dc=com"
        by users read

access to dn.base="ou=users,ou=handler,dc=eastcom-ca,dc=com"
        by self write
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by users read

access to dn.base="ou=groups,ou=handler,dc=eastcom-ca,dc=com"
        by self write
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by users read

access to dn.base="ou=managed,dc=eastcom-ca,dc=com"
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by users read

access to dn.base="ou=targets,ou=managed,dc=eastcom-ca,dc=com"
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by users read

access to dn.base="ou=midden,ou=targets,ou=managed,dc=eastcom-ca,dc=com"
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by users read

access to dn.one="ou=midden,ou=targets,ou=managed,dc=eastcom-ca,dc=com"
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by users read

access to dn.base="ou=JMS,dc=eastcom-ca,dc=com"
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by users read

access to *
        by group="cn=administrator,ou=groups,ou=handler,dc=eastcom-ca,dc=com" write
        by self write
        by aci write


database        bdb
suffix          "dc=eastcom-ca,dc=com"
rootdn          "cn=admin,dc=eastcom-ca,dc=com"
# Cleartext passwords, especially for the rootdn, should
# be avoid.  See slappasswd( and slapd.conf(5) for details.
# Use of strong authentication encouraged.
rootpw          {SHA}0DPiKuNIrrVmD8IUCuw1hQxNqZc=
# 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 default pres,eq
index   objectClass     eq 询问一下原因
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP