0

I have installed openldap server on a server with redhat7.7 when I start it, I get an error.

I get the following

#systemctl status slapd.service
● slapd.service - OpenLDAP Server Daemon
   Loaded: loaded (/usr/lib/systemd/system/slapd.service; disabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Wed 2019-11-13 03:37:09 CST; 7min ago
     Docs: man:slapd
           man:slapd-config
           man:slapd-hdb
           man:slapd-mdb
           file:///usr/share/doc/openldap-servers/guide.html
  Process: 104932 ExecStart=/usr/sbin/slapd -u ldap -h ${SLAPD_URLS} $SLAPD_OPTIONS (code=exited, status=1/FAILURE)
  Process: 104900 ExecStartPre=/usr/libexec/openldap/check-config.sh (code=exited, status=0/SUCCESS)

Nov 13 03:37:09 ServerG runuser[104925]: pam_unix(runuser:session): session c...p
Nov 13 03:37:09 ServerG runuser[104927]: pam_unix(runuser:session): session o...)
Nov 13 03:37:09 ServerG runuser[104927]: pam_unix(runuser:session): session c...p
Nov 13 03:37:09 ServerG runuser[104929]: pam_unix(runuser:session): session o...)
Nov 13 03:37:09 ServerG runuser[104929]: pam_unix(runuser:session): session c...p
Nov 13 03:37:09 ServerG slapd[104932]: @(#) $OpenLDAP: slapd 2.4.44 (Dec 18 ... $
                                                                   mockbuild@x86-017.build.eng.b...pd
Nov 13 03:37:09 ServerG systemd[1]: slapd.service: control process exited, c...=1
Nov 13 03:37:09 ServerG systemd[1]: Failed to start OpenLDAP Server Daemon.
Nov 13 03:37:09 ServerG systemd[1]: Unit slapd.service entered failed state.
Nov 13 03:37:09 ServerG systemd[1]: slapd.service failed.
Hint: Some lines were ellipsized, use -l to show in full.

I have searched a lot and tried 100 things, none helped when I try to run it manually I get the following error at the very end. do you think it says that I dont have SSL configured?

TLSMC: MozNSS compatibility interception ends.
TLS: could not use certificate `OpenLDAP Server'.
TLS: error:0200100D:system library:fopen:Permission denied bss_file.c:402
TLS: error:20074002:BIO routines:FILE_CTRL:system lib bss_file.c:404
TLS: error:140AD002:SSL routines:SSL_CTX_use_certificate_file:system lib ssl_rsa.c:468
5dcbcf86 main: TLS init def ctx failed: -1
5dcbcf86 slapd destroy: freeing system resources.
5dcbcf86 slapd stopped.
5dcbcf86 connections_destroy: nothing to destroy.

How can I fix it?

  • To me it seems that the perms of the 'OpenLDAP Server' are incorrect. – schaiba Nov 13 '19 at 15:15
  • @schaiba I have been trying a loooooot. even asked redhat support I did not get this fixed. what would you recommend? would you please do me a favor and help me solve it? – Learner Nov 13 '19 at 15:16
  • What are the permissions on that certificate? – schaiba Nov 13 '19 at 15:18
  • @schaiba I am root, I can assign read and write to any file – Learner Nov 13 '19 at 15:31
0

Try this:

Enable slapd on boot

systemctl enable slapd.service

Check the Selinux status

sestatus

Disable Selinux

setenforce Permissive
|improve this answer|||||
  • 1
    enabling the service is a reasonable step to take, since it's listed as "disabled", but this answer doesn't address why the service doesn't start. Disabling SE Linux is not something that should be the first reaction, particularly when there's no evidence of SE Linux interference here. – Jeff Schaller Dec 2 '19 at 19:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for?Browse other questions tagged or ask your own question.