Community Articles
Find and share helpful community-sourced technical articles
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.
Labels (1)
Rising Star

OBJECTIVE:

Set logging level within DLM to "DEBUG" for all components to provide more detail when troubleshooting DLM/DSS issues such as pairing problems.

OVERVIEW:

Using some Docker and bash sleight of hand, update the logback configuration in the DLM Docker container to direct the application to log at a more verbose DEBUG level.

PREREQUISITES:

Root access or sudo on the DLM host.

STEPS:

1. Find the running Docker container for DLM on the host running DPS/DLM.

sudo docker ps 

77570-docker-ps-output.png

Note the docker container ID running dlm-app.

2. Get the current log configuration file from the container

sudo docker exec -it <container ID> /bin/cat /usr/dlm-app/conf/logback.xml | tee logback.xml.local

3. Using vi or your favorite editor, update the logging configuration section below in the new local copy logback.xml.local, setting to "DEBUG" where desired:

...

<logger name="play" level="DEBUG" />
<logger name="application" level="DEBUG" />
<root level="DEBUG">
    <appender-ref ref="ASYNCFILE" />
    <appender-ref ref="ASYNCSTDOUT" />
</root>

...

4. Deploy the new configuration to the Docker container

sudo docker exec -i <container ID> cp /usr/dlm-app/conf/logback.xml /usr/dlm-app/conf/logback.xml.bak
sudo docker exec -i <container ID> tee /usr/dlm-app/conf/logback.xml < logback.xml.local

5. Restart the Docker container

sudo docker restart <container ID>

6. View the log output

sudo docker exec -it <container ID> /bin/tailf /usr/dlm-app/logs/application.log

or

sudo docker logs <container ID>

To restore the previous level of logging, replace /usr/dlm-app/logs/application.log with the backup made in step 4 (/usr/dlm-app/conf/logback.xml.bak).

316 Views
Don't have an account?
Coming from Hortonworks? Activate your account here
Version history
Revision #:
2 of 2
Last update:
‎08-17-2019 07:13 AM
Updated by:
 
Contributors
Top Kudoed Authors