Openldap

包含第二個模式後,openLDAP 不會啟動

  • September 14, 2018

我有一台安裝了 openLDAP 的 Mac(使用 Macports)。我已經啟動了系統並且能夠創建對象。我在 slapd.conf 中配置的唯一架構是 core.schema。

我正在尋找添加 nis.schema,但是當我嘗試這個slapd -d3命令對我不起作用。具體來說,它說:

5b994529 @(#) $OpenLDAP: slapd 2.4.28 (Oct 14 2016 16:25:43) $
   root@osx234.apple.com:/Library/Caches/com.apple.xbs/Binaries/OpenLDAP/OpenLDAP-523.30.2~39/TempContent/Objects/servers/slapd
5b994529 daemon: SLAP_SOCK_INIT: dtblsize=256
5b994529 daemon_init: listen on ldap:///
5b994529 daemon_init: 1 listeners to open...
ldap_url_parse_ext(ldap:///)
5b994529 daemon: listener initialized ldap:///
5b994529 daemon_init: 2 listeners opened
5b994529 daemon_init: [0]DNSServiceRegister
ldap_create
5b994529 slapd init: initiated server.
5b994529 int pws_auxprop_init(const sasl_utils_t *, int, int *, sasl_auxprop_plug_t **, const char *): entered5b994529 slap_sasl_init: initialized!
5b994529 bdb_back_initialize: initialize BDB backend
5b994529 bdb_back_initialize: Berkeley DB 4.7.25: (May 15, 2008)
5b994529 hdb_back_initialize: initialize HDB backend
5b994529 hdb_back_initialize: Berkeley DB 4.7.25: (May 15, 2008)
5b994529 ==> OD Locales overlay initialize called 
5b994529 ==> translucent_initialize
5b994529 slapd destroy: freeing system resources.
5b994529 slapd stopped.
5b994529 connections_destroy: nothing to destroy.
tlsst_destroy()

我無法找到任何日誌來縮小原因。我怎樣才能導入這個模式並且仍然讓 slapd 成功執行?

編輯

我已經執行 slapd -d-1 進行額外的日誌記錄。如果需要,我可以提供完整的日誌,但我認為以下內容可能是罪魁禍首:

5b9a54a1 /opt/local/etc/openldap/schema/nis.schema: line 203 (objectclass ( 1.3.6.1.1.1.2.6 NAME 'ipHost' DESC 'Abstraction of a host, an IP device' SUP top AUXILIARY MUST ( cn $ ipHostNumber ) MAY ( l $ description $ manager ) ))
5b9a54a1 /opt/local/etc/openldap/schema/nis.schema: line 203 objectclass: AttributeType not found: "manager"

這是我缺少的依賴項嗎?

基於https://github.com/openshift/openldap/blob/master/2.4.41/contrib/config/schema/nis.schema(以及其他參考資料)說:

取決於 core.schema 和 cosine.schema

include在包含 nis.schema 之前,您需要這些:

include /opt/local/etc/openldap/schema/core.schema
include /opt/local/etc/openldap/schema/cosine.schema
# ...
include /opt/local/etc/openldap/schema/nis.schema

引用自:https://unix.stackexchange.com/questions/468616