<?xml version="1.0" encoding="UTF-8"?>
<!--
! CCPL HEADER START
!
! This work is licensed under the Creative Commons
! Attribution-NonCommercial-NoDerivs 3.0 Unported License.
! To view a copy of this license, visit
! http://creativecommons.org/licenses/by-nc-nd/3.0/
! or send a letter to Creative Commons, 444 Castro Street,
! Suite 900, Mountain View, California, 94041, USA.
!
! You can also obtain a copy of the license at
! trunk/opendj3/legal-notices/CC-BY-NC-ND.txt.
! See the License for the specific language governing permissions
! and limitations under the License.
!
! If applicable, add the following below this CCPL HEADER, with the fields
! enclosed by brackets "[]" replaced with your own identifying information:
! Portions Copyright [yyyy] [name of copyright owner]
!
! CCPL HEADER END
!
! Copyright 2011-2012 ForgeRock AS
! Portions Copyright 2013 Jens Elkner
!
-->
<refentry xml:id="dsjavaproperties-1" xmlns="http://docbook.org/ns/docbook"
version="5.0" xml:lang="en"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://docbook.org/ns/docbook http://docbook.org/xml/5.0/xsd/docbook.xsd"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:include href="common.xml" xpointer='xpointer(//info[@name="info"])'/>
<refmeta>
<refentrytitle><application>dsjavaproperties</application></refentrytitle>
<xi:include href="common.xml" xpointer='xpointer(//manvolnum[@name="v1m"])'/>
</refmeta>
<refnamediv>
<refname><application>dsjavaproperties</application></refname>
<refpurpose>apply OpenDJ Java home and JVM settings</refpurpose>
</refnamediv>
<refsynopsisdiv>
<cmdsynopsis>
<command>dsjavaproperties</command>
<xi:include href="common.xml"
xpointer='xpointer(//para[@name="s-misc"]/*[@name="sc-quiet"])'/>
<xi:include href="common.xml"
xpointer='xpointer(//para[@name="s-general"]/*)'/>
<arg os="solaris"><replaceable class="parameter">properties_file</replaceable></arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsection>
<title>Description</title>
<para>
This utility can be used to change the Java arguments and Java home that are
used by OpenDJ server commands and tools.
</para>
<para os="solaris">
If <filename><replaceable>properties_file</replaceable></filename> is given and denotes a regular file
readable by the user ldapd, it gets copied to
<varname>$INSTANCE_ROOT</varname><filename>/config/java.properties</filename>.
It allows users, which have the "OpenDJ Admin" profile assigned, to change the
content of the file, even if they are not allowed to explicitly <citerefentry>
<refentrytitle>su</refentrytitle><xi:include href="common.xml"
xpointer='xpointer(//manvolnum[@name="v1m"])'/></citerefentry> to the owner of
the <varname>$INSTANCE_ROOT</varname> or change the ACLs of this file.
</para>
<para>
<command>dsjavaproperties</command> reads
<varname>$INSTANCE_ROOT</varname><filename>/config/java.properties</filename>
and persists all changes, so that other OpenDJ utilities are able to use them.
</para>
<note>
<para>
Changes are <emphasis>not</emphasis> propagated to tools already running.
</para>
</note>
<para>
The file is a simple <link
xlink:href="http://docs.oracle.com/javase/7/docs/api/java/util/Properties.html#load%28java.io.Reader%29">Java property file</link>.
All honored keys or key patterns are explained in the <varname
>$INSTALL_ROOT</varname><filename>/template/config/java.properties</filename>
example.
</para>
</refsection>
<refsection>
<title>Options</title>
<para>The following options are supported.</para>
<variablelist>
<xi:include href="common.xml"
xpointer='xpointer(//para[@name="l-misc"]/*[@name="lc-quiet"])'/>
<xi:include href="common.xml"
xpointer='xpointer(//para[@name="l-general"]/*)'/>
</variablelist>
</refsection>
<refsection>
<title>Examples</title>
<informalexample>
<literallayout><prompt
>$ </prompt><command>dsjavaproperties</command></literallayout>
<screen>
The operation was successful. The server commands will use the java
arguments and java home specified in the properties file located in
$INSTANCE_ROOT/config/java.properties
</screen>
</informalexample>
</refsection>
<xi:include href="common.xml" xpointer='xpointer(//refsection[@name="env"])'/>
<xi:include href="common.xml" xpointer='xpointer(//refsection[@name="exit-0-gt0"])'/>
<refsection>
<title>Files</title>
<variablelist>
<varlistentry>
<term><varname>$INSTANCE_ROOT</varname><filename>/config/java.properties</filename></term>
<listitem>
<para>
Contains the properties to persist.
</para>
</listitem>
</varlistentry>
</variablelist>
<variablelist>
<varlistentry>
<term><varname>$INSTALL_ROOT</varname><filename>/template/config/java.properties</filename></term>
<listitem>
<para>
An example of a java.properties file incl. documentation and examples.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsection>
<xi:include href="common.xml" xpointer='xpointer(//refsection[@name="seeAlso"])'/>
</refentry>