Configuring Periodic Stacks Collection

You can enable and configure periodic stacks collection.

Minimum Required Role: Configurator (also provided by Cluster Administrator, Limited Cluster Administrator , and Full Administrator)

  1. Open the Cloudera Manager page for a specific service or role.
  2. Access the configuration settings in one of the following ways:
      1. From the service page in Cloudera Manager, click the Configuration tab.
      2. Select Scope > NameNode.
      3. Select Category > Stacks Collection.
      1. From the service page in Cloudera Manager, click the Instances tab.
      2. Click the Configuration tab.
      3. Select Scope > role type .
      4. Select Category > Stacks Collection.
The configuration settings are as follows:
  • Stacks Collection Enabled - Whether or not periodic stacks collection is enabled.
  • Stacks Collection Directory - The directory in which stack logs will be placed. If not set, stacks will be logged into a stacks subdirectory of the role's log directory.
  • Stacks Collection Frequency - The frequency with which stacks will be collected.
  • Stacks Collection Data Retention - The amount of stacks data that will be retained. When the retention limit is reached, the oldest data will be deleted.
  • Stacks Collection Method - The method that will be used to collect stacks. The jstack option involves periodically running the jstack command against the role's daemon process. The servlet method is available for those roles with an HTTP server endpoint that exposes the current stacks traces of all threads. When the servlet method is selected, that HTTP endpoint is periodically scraped.
As an example, to configure stacks collection for an HDFS NameNode, complete the following steps:
  1. Go to the HDFS service page.
  2. Click the Configuration tab.
  3. Select Scope > NameNode.
  4. Select Category > Stacks Collection.
  5. Locate the property or search for it by typing its name in the Search box.
  6. Modify the configuration settings if desired.
  7. Click Save Changes.

Stacks collection configuration settings are stored in a per-role configuration file called Cloudera Manager reads the configuration file and coordinates stack collection. Changes to the configuration settings take effect after a short delay. It is not necessary to restart the role.