Certain command-line utilities can use a common properties file to provide default values for options such as the following:
The host name and port number of the directory server
Whether to use SSL or StartTLS to communicate with the directory server
The bind DN to use when connecting to the server
The following utilities can use a properties file:
The following mutually exclusive options are used with the command-line utilities to indicate whether a properties files is used:
Indicates that the properties file is not used to obtain default values for command-line options.
Utilities that use the common properties file have the following default behavior:
If the --noPropertiesFile option is specified, the command-line interface does not try to locate a properties file. Only options specified on the command line are evaluated.
If the --propertiesFilePath option is specified, property values are read from this file.
If neither --propertiesFilePath nor --noPropertiesFile is specified, the command-line interface attempts to find a properties file in the following locations:
If no properties file is found in either of these locations, the default behavior is applied (only arguments specified on the command line are evaluated).
If an option is provided on the command line, this option and its corresponding value are used by the command-line interface. In other words, options specified on the command line take precedence over the properties defined in the properties file.
The properties file has the standard JAVA properties file format (property-name=value). As such, the file supports variations on property names to enable them to be overridden according to the command that uses them. For example, the properties file might contain the following:
hostname=localhost port=4444 bindDN=cn=Directory Manager bindPassword=password baseDN=dc=example,dc=com searchScope=sub sortOrder=givenName virtualListView=0:2:1:0
If a command-line interface uses the port property, the command first tries to locate a toolname.port definition. If this is not defined, the command tries to locate a port definition. For example, the properties file might have several port options defined for different utilities:
port=4444 ldapsearch.port=1389 ldapcompare.port=1389 ldapmodify.port=1389 ldapdelete.port=1389
Note - Do not use quotation marks around the values in the properties file (for example, port="4444").