Pivotal Knowledge Base

Follow

How to Enable Debug Logging in Ambari Agent

Environment

Product Version
Pivotal HD / Pivotal HDP 3.0.x / 2.3, 2.4
Ambari 2.x

Purpose

When troubleshooting Ambari issues, it may be necessary to enable debug logging in the Ambari Agent log /var/log/ambari-agent/.

If there is a need to enable debug on the Ambari server, see How to enable debug logging in Ambari Server

Procedure

To enable debug logging in Ambari agent, follow these steps:

1. Open the relevant configuration file in a UNIX text editor: 

  • Ambari Agent: /etc/ambari-agent/conf/ambari-agent.ini

2. Locate (or add in the entry) loglevel

[root@hawq20 conf]# grep loglevel ambari-agent.ini
;loglevel=(DEBUG/INFO)
loglevel=INFO
[root@hawq20 conf]#

3. Replace "loglevel=INFO" with "loglevel=DEBUG":

[root@hawq20 conf]# grep loglevel ambari-agent.ini
;loglevel=(DEBUG/INFO)
loglevel=DEBUG
[root@hawq20 conf]#

4. Save the configuration file and close it.

5. Restart Ambari agent: 

ambari-agent restart

NOTE: Ambari agent logging level will only change on one host and will not affect the other hosts in the cluster.

 

 

Comments

Powered by Zendesk