Enabling default logging

You can enable default logging for the command-line interface.

Set the environment variable scm_log to 1 to enable default logging for the command-line interface. The logs are located under USER_HOME/.jazz-scm/logs/. If the --config option is set, then the logs are under CONFIG_DIR/.jazz-scm/logs. The log rotation is set to 10 files with 5 megabytes each. You can also set log.level in USER_HOME/.jazz-scm/preference.properties to a required value and uncomment it.

The preference.properties file contains the following text:

Logging level.
This value is used only in case of default logging. 
The levels in descending order are:
SEVERE (highest value)
WARNING
INFO
CONFIG
FINE
FINER
FINEST (lowest value)
By default, logging level is set to severe. This is to done to avoid bloating the disk with logs.
# log.level: SEVERE

Log4j and Java util Logging for CLI

Set either of the following environment variables log4j_properties or java_util_logging to the path of the properties file. You can find a sample file for each of the following logging methods.

To enable log4j logging, in addition to specifying the log4j_properties environment variable,
  1. Copy the org.apache.commons.logging.log4j fragment for the org.apache.commons.logging plug-in into the scmTools\eclipse\plugins directory from the corresponding server build which is found at the directory server/conf/ccm/sites/rtc-commons-update-site/plugins. For more information on why the fragment is required, see Logger bundles need WS-SecurityPolicy and commons-logging fails to discover available logging systems.
  2. Add the following VM argument to the scm.ini file.
    -Dcom.ibm.team.jfs.app.install.logging.log4j.v2.enabled=true