Skip to main content

Using MarkLogic Content Pump (mlcp)

Enabling Debug Level Messages

You can enable debug level log messages to see detailed debugging information about what mlcp is doing. Debug logging generates many messages, so you should not enable it unless you need it to troubleshoot a problem.

To enable debug logging:

For versions of mlcp 10 earlier than 10.0-8.2:

  1. Edit the file MLCP_INSTALL_DIR/conf/log4j.properties. For example, if mlcp is installed in /opt/mlcp, edit /opt/mlcp/conf/log4j.properties.

  2. In log4j.properties, set the properties log4j.logger.com.marklogic.mapreduce and log4j.logger.com.marklogic.contentpump to DEBUG. For example, include the following:

    log4j.logger.com.marklogic.mapreduce=DEBUG
    log4j.logger.com.marklogic.contentpump=DEBUG

    You may find these property settings are already at the end of log4j.properties, but commented out. Remove the leading # to enable them.

In 10.0-8.2, we migrated log4j to log4j2 due to security vulnerabilities. For mlcp 10 versions 10.0-8.2 and later:

  1. Edit the file MLCP_INSTALL_DIR/conf/log4j2.xml. For example, if mlcp is installed in /opt/mlcp, edit /opt/mlcp/conf/log4j2.xml.

  2. In log4j2.xml, set the level to DEBUG for logger com.marklogic.mapreduce and com.marklogic.contentpump. For example, include the following:

    <Logger name="com.marklogic.mapreduce" level="DEBUG" additivity="false">
      <AppenderRef ref="Console"/>
    </Logger>
    <Logger name="com.marklogic.contentpump" level="DEBUG" additivity="false">
      <AppenderRef ref="Console"/>
    </Logger>

    You may find these property settings are already in log4j2.xml, but commented out. Remove the leading <!-- and --> to enable them.