2.2.2 - RPM Instance Layout¶
When you run the installer on your RPM based system, it will install the server on your disk, using this layout :
/ | +-- etc/ | | | +-- init.d/ | | | +-- apacheds-<version>-<instance> The daemon used to start the server +-- opt/ | | | +-- apacheds-<version> | | | +-- conf/ | | | | | +-- wrapper.conf The wrapper default configuration | | | +-- bin/ | | | | | +-- apacheds* The script that starts the server | | | | | +-- wrapper* The binary that starts the server | | | +-- lib | | | | | +-- wrapper-3.2.3.jar | | | | | +-- libwrapper.so | | | | | +-- apacheds-wrapper-2.0.0-M20-SNAPSHOT.jar | | | | | +-- apacheds-service-2.0.0-M20-SNAPSHOT.jar | | | +-- NOTICE | | | +-- LICENSE | +-- var/ | +--lib/ | +-- apacheds-<version>/ | +-- <instance>/ | +-- run/ | | | +-- apacheds-default.pid The PID of the running process | +-- partitions/ This is were your data will be stored | | | +-- schema/ | | | +-- system/ | | | +-- example/ | +-- log/ This is were the logs are stored | | | +-- apacheds.log | | | +-- wrapper.log | +-- cache/ This is where the various caches are stored | | | +-- changePwdReplayCache.data | | | +-- ou=system.data | | | +-- groupCache.data | | | +-- kdcReplayCache.data | +-- conf/ | +-- wrapper-instance.conf The specific instance wrapper configuration | +-- log4j.properties The log configuration file | +-- config.ldif The server configuration. Don't manipulate this file with a text editr !
As we can have more than one instance, we have more than one directory in /var/lib/apacheds that can be installed. Each one of these instance can be started using the /etc/init.d/apacheds daemon, passing the instancz as a parameter :
$ sudo /etc/init.d/apacheds-<version> start <instance>
The default instance name is 'default'.
All the data for a given instance are stored into this /var/lib/apacheds-
Configuring each instance¶
You can configure a specific settings. This is done by modifying the configuration files in /var/lib/apacheds-
JVM setting¶
Were you to change the memory you want to use for a given instance, you will have to modify the /var/lib/apacheds-
## ## In this file you can override parameters specified in the default ## Apache Directory Server config file which is usually at ## /opt/apacheds-2.0.0-M20-SNAPSHOT/conf/wrapper.conf ## ## See also http://wrapper.tanukisoftware.org/doc/english/properties.html ## For a list of properties that can be set. ## ## Override the JRE used # wrapper.java.command=<path-to-java-executable> ## Override the JVM memory settings ## Initial Java Heap Size (in MB) # wrapper.java.initmemory=1024 ## Maximum Java Heap Size (in MB) # wrapper.java.maxmemory=2048
You mainly want to change the memory used by the JVM.
Log configuration¶
You can configure the log level and content by changing the content of the /var/lib/apacheds-
The default configuration is given below :
log4j.rootCategory=WARN, R, stdout log4j.appender.stdout=org.apache.log4j.ConsoleAppender log4j.appender.stdout.layout=org.apache.log4j.PatternLayout log4j.appender.R=org.apache.log4j.RollingFileAppender log4j.appender.R.File=${apacheds.log.dir}/apacheds.log log4j.appender.R.MaxFileSize=1024KB # Keep some backup files log4j.appender.R.MaxBackupIndex=5 log4j.appender.R.layout=org.apache.log4j.PatternLayout log4j.appender.R.layout.ConversionPattern=[%d{HH:mm:ss}] %p [%c] - %m%n log4j.appender.stdout.layout.ConversionPattern=[%d{HH:mm:ss}] %p [%c] - %m%n # with these we'll not get innundated when switching to DEBUG log4j.logger.jdbm.recman.BaseRecordManager=FATAL log4j.logger.org.apache.directory.server.OPERATION_LOG=FATAL log4j.logger.org.apache.directory.server.OPERATION_TIME=FATAL log4j.logger.org.apache.directory.api.CODEC_LOG=FATAL log4j.logger.org.apache.directory.server.ACI_LOG=FATAL # Replication logs log4j.logger.org.apache.directory.server.PROVIDER_LOG=FATAL log4j.logger.org.apache.directory.server.CONSUMER_LOG=FATAL # Search log log4j.logger.org.apache.directory.CURSOR_LOG=FATAL # Other logs log4j.logger.org.apache.directory.api=FATAL log4j.logger.org.apache.directory.server=FATAL log4j.logger.net.sf.ehcache=FATAL log4j.logger.org.apache.mina=FATAL