slapd not running

6,292

first off, are you sure its not running by checking the following commands;

You can check that the ldap is actually running by using the command netstat -lntp | grep 389 and it should show something like this;

# netstat -lntp | grep 389
tcp        0      0 0.0.0.0:389                 0.0.0.0:*                   LISTEN      28783/slapd         
tcp        0      0 :::389                      :::*                        LISTEN      28783/slapd

If it is not running then try and start the command from the command line (so you can see any error messages to standard outout/error) like so;

# /usr/sbin/slapd -d 1
@(#) $OpenLDAP: slapd 2.3.43 (Feb 22 2012 15:59:04) $
        [email protected]:/builddir/build/BUILD/openldap-2.3.43/openldap-2.3.43/build-servers/servers/slapd
daemon_init: listen on ldap:///
daemon_init: 1 listeners to open...
...
slapd starting

my log file seems to be located by default in /var/log/slapd.log , so that is the first place to look for additional information.

If it is definitely not starting, then you can edit the /etc/openldap/slapd.conf file to increase the logging activity with the loglevel command;

#<http://www.zytrax.com/books/ldap/ch6/#loglevel>
#loglevel 3333
#loglevel filter
#loglevel stats
#loglevel ACL
Share:
6,292

Related videos on Youtube

Infotechie
Author by

Infotechie

Updated on September 18, 2022

Comments

  • Infotechie
    Infotechie over 1 year

    I am new to Red Hat Enterprise Linux 5.3(Tikanga) as well as to open ldap.As openldap comes by default with the red hat.So i have installed berkeley database db-5.3.15.tar.gz

    Version of already installed OpenLdap: openldap-2.3.43-3.el5

    When I am running slapd by command:

    service ldap start

    It is showing

    Starting slapd: [ OK ]

    but no slapd process is starting. Please suggest what is the problem.

    Thanks.

    • Infotechie
      Infotechie about 12 years
      where can i see the log?
    • Infotechie
      Infotechie about 12 years
      besides this already installed openldap. I have installed both openldap and berkley db and tried to run it through slapd instead of service ldap start but that is also not running. Is it something like on red hat linux we can run openldap through "service ldap start" only?
  • Infotechie
    Infotechie about 12 years
    Thanks for the valuable information. It really helped me.Can you please guide how can I change the default port?
  • gokva
    gokva about 12 years
    put something like SLAPD_OPTIONS="-h ldap://localhost:12345" in /etc/sysconfig/ldap
  • Infotechie
    Infotechie about 12 years
    there is no such directory/file named ldap i.e. i am only able to get /etc/openldap/ Inside this there is not ldap options. Any idea?
  • Infotechie
    Infotechie about 12 years
    i have run the following command and it worked: slapd -h ldap://localhost:12345 -f usr/local/openldap_2.4/slapd.conf. But now i have another query how can i know which BDB it is referring as there are two bdb one is default and other is installed by me?
  • gokva
    gokva about 12 years
    Its dependent on how you configured the additional root. I'd need to see the slapd.conf file. You can award this answer and paste the slapd.conf in another question and link to it here, and ill take a look.
  • Infotechie
    Infotechie about 12 years
    I have raised another question: serverfault.com/questions/382893/… Please have a look and provide your suggestion.
  • gokva
    gokva about 12 years
    re the /etc/sysconfig/ldap its not there by default, but you can create it and the service ldap start script looks in that file for addition options. You can open the /etc/init.d/ldap in a text editor and search for the /etc/sysconfig and SLAPD_OPTIONS strings for details on how those values are used.
  • ILMostro_7
    ILMostro_7 almost 9 years
    the filename is actually /etc/sysconfig/slapd instead of /etc/sysconfig/ldap