5.1 - Layout

5.1.1 General Layout

The general layout for ApacheDS is fairly simple and consists in two major concepts:

  • an installation layout
  • an instance layout

5.1.1.1 Installation Layout

The installation is where are stored all files essential to ApacheDS like the launch script, libraries, eventually a service wrapper (depending on the kind of installer used).

The most common installation, shared by all ApacheDS installers, can be described as follows:

[Installation-Layout]
    |- bin/
        |- apacheds (or 'apacheds.exe' on Windows)
        |- wrapper (or 'wrapper.exe' on Windows)
    |- conf/
        |- wrapper.conf
    |- lib/
        |- apacheds-service-${version}.jar
        |- apacheds-wrapper-${version}.jar
        |- libwrapper.jnilib (or 'libwrapper.so', or 'libwrapper.dll' depending on the platform)
        |- wrapper-3.2.3.jar
    |- LICENSE
    |- NOTICE
  • The bin/ directory contains the apacheds launch script and wrapper binary used to configure ApacheDS as a service.
  • The conf/ directory holds the general configuration for the service in wrapper.conf.
  • The lib/ directory contains all ApacheDS and wrapper libraries necessary to run the server.
  • LICENCE and NOTICE files contains the required legal information about ApacheDS.

5.1.1.2 Instance Layout

ApacheDS is built to be able to run multiple instances of the server at the same time, which means that optionally an instances folder can be found in the installation layout (or elsewhere on disk depending on the platform). In that folder, can be found a single or multiple directories, all sharing the same layout, corresponding to all ApacheDS instance (one directory per instance, named by the id of the instance).

Here’s how this instance layout can be described:

[Instance-Layout]
    |- cache/
        |- [...]
    |- conf/
        |- config.ldif
        |- log4j.properties
        |- wrapper.conf
    |- log/
        |- apacheds.log
        |- wrapper.log
    |- partitions/
        |- example/
            |- [...]
        |- schema/
            |- [...]
        |- system/
            |- [...]
  • The cache/ directory is empty upon installation and contains all the data required for the cache system after the first start of the server.
  • The conf/ directory contains:
    • an additional wrapper.conf where general configuration defined in the installation layout can be overwritten for the given instance.
    • a log4j.properties file which is responsible for logging configuration.
    • a config.ldif file corresponding to the inner configuration of ApacheDS.
  • The log/ directory is empty upon installation and contains two files after the first start of the server:
    • a apacheds.log which is where all logs defined in the log4j.properties go.
    • a wrapper.log which only contains the wrapper logs (related to the service’s start/stop).
  • The partitions/ directory is empty upon installation and contains after the first start of the server a directory for each partition defined in the configuration:
    • the example/ directory holds the data for the “example” partition defined in ApacheDS’ default configuration.
    • the schema/ and system/ directories contain the data for both internal “schema” and “system” partitions.

5.1.2 Specific Layouts

Depending on the type of distribution used to install ApacheDS, the layout varies to adapt as best as possible to the specificities of each platform.

5.1.2.1 Archive Distribution (zip/tar.gz)

The Archive distribution consist of a compressed directory containing everything needed to run ApacheDS. It doesn’t install on the machine and does not require any extra permission (root user, installer password, etc.). The directory is simply unarchived and ApacheDS is ready to be launched.

The installation layout is a bit simpler for this kind of distribution since no wrapper is distributed, the application being run in a terminal or via the .bat script.

[Installation-Layout]
    |- bin/
        |- apacheds.bat
        |- apacheds.sh
        |- cpappend.bat
    |- instances/
    |- lib/
        |- apacheds-service-${version}.jar
    |- LICENSE
    |- NOTICE
  • The bin/ directory contains the apacheds.bat (Windows) and apacheds.sh (Linux/Unix) launch scripts and a cpappend.bat utility (only used on Windows).
  • The instances/ directory hold all ApacheDS instances (an instance named default is provided by default).
  • The lib/ directory only contains the ApacheDS library.
  • LICENCE and NOTICE files contains the required legal information about ApacheDS.

5.1.2.2 Windows Installer (.exe)

The Windows installer uses the general installation and instances layout.

By default, the installation directory is:

C:\Program Files\ApacheDS

An instances/ directory in the installation layout holds all ApacheDS instances (an instance named default is provided by default).

ApacheDS is registered as a service on Windows. Operations on the service can be achieved in the Services utility which is accessible via Start > Contol Panel > Administration Tools > Services.

5.1.2.3 Linux Binary (.bin), Debian (.deb) & Fedora (.rpm) Installers

The Mac OS X installer uses the general installation and instances layout.

By default, the installation directory is:

/opt/apacheds-${version}

All ApacheDS instances are located in a directory at the following location (an instance named default is provided by default):

/var/lib/apacheds-${version}

The installer also adds a shortcut launch script for the default instance at:

/etc/init.d/apacheds-${version}-default

NOTE: The ApacheDS Linux Binary installer lets the user decide the locations of the installation directory, the instances directory and the default instance launch script. The locations above refer to the default location and need to be adapted to whatever path was chosen during the installation.

5.1.2.4 Mac OS X Installer (.pkg)

The Mac OS X installer uses the general installation and instances layout.

By default, the installation directory is:

/usr/local/apacheds-${version}

An instances/ directory in the installation layout holds all ApacheDS instances (an instance named default is provided by default).

The installer also adds a shortcut to the command in the bin directory called “apacheds", accessible directly in a terminal and located at:

/usr/bin/apacheds