I installed the .DEB package of ApacheDS 1.5.7 on a clean Ubuntu 11.04 server. I got the DEB from here. It installed and started itself automatically and was running, but I don't know how to start/stop/restart it. I don't know if it's set to auto-run at boot either. The official documentation doesn't actually say how to either.

I changed the port in /var/lib/apacheds-1.5.7/default/conf/server.xml per the instructions, but the instructions just say "restart the server", no indication of how that is done.

There is an init file, /etc/init.d/apacheds-1.5.7-default, which seems like it would be what I want but:

root@(none):~# /etc/init.d/apacheds-1.5.7-default start
   Starting Apache Directory Server - default...
root@(none):~# /etc/init.d/apacheds-1.5.7-default stop
   Stopping Apache Directory Server - default...
   Apache Directory Server - default was not running

It appears as if the start command, while giving no errors, is not actually starting DS?

Attempting to access the server from a Client Machine Running Apache Directory Studio produces a "connection refused" error. I changed the port back to what it was and doubed checked for errors in the config file, but I've been unable to start the Directory Server again. Rebooting the server did not cause it to auto-start.

I found no folder in /var/log calle "apacheds" or similar, and don't see any entries in syslog.

How do I start/stop/restart DS and confirm if it is or is not running?


java -version


java version "1.6.0_26"
Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
Java HotSpot(TM) 64-Bit Server VM (build 20.1-b02, mixed mode)
  • Did you install an JRE on the machine? apt-get install openjdk-6-jre.
    – Sven
    Feb 6, 2012 at 1:26
  • With an JRE installed, all worked as expected, without it the system behaved like you described. Anyway, I doubt this will solve your LDAP problems. You are replacing a well-known and documented solution with many active users with something that is seldom used and not supported on your platform of choice.
    – Sven
    Feb 6, 2012 at 1:28
  • Yes, I have JRE installed. I've included the output of "java -version" above. After I installed the .DEB it was running and I was able to connect to it. After changing the port though I was unable to figure out how to get it to restart, and it boots up not running. I can try again with OpenLDAP. I just need something that works and is reliable. (And by 'works' I mean "works when I try it").
    – Nick
    Feb 6, 2012 at 1:51
  • Probably should be noted: apacheds won't listen network if started as root user sometimes. Edit wrapper script to set apacheds/apacheds pid/gid for it.
    – kagali-san
    Feb 2, 2015 at 11:32

2 Answers 2


Start and stop should work with:
root@(none):~# /etc/init.d/apacheds-1.5.7-default start|stop

How to confirm:
usually when apacheds is started a file is created in /var/run/apacheds/default/default.pid with the pid of apacheDS, check the content of this file. You can do

ps `cat /var/run/apacheds/default/default.pid`

ps -fea | grep -i apacheds


For standalone installations of ApacheDS, the run directory is


... and so to reset the default pid file do:

$ sudo rm /var/lib/apacheds-2.0.0-M16/default/run/apacheds-default.pid

(replace -2.0.0-M16 with your version, of course)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .