Enabling OpenTelemetry instrumentation agent for HBase components

Enable the OpenTelemetry instrumentation agent to capture HBase performance metrics, manage Prometheus exporter configurations, and monitor cluster runtimes.

You can configure the OpenTelemetry (OTel) javaagent framework using Cloudera Manager to collect metrics directly from your HBase Master and RegionServer daemons.
  1. Log in to the Cloudera Manager Admin Console.
  2. Navigate to the HBase service page and click the Configuration tab.
  3. Locate the Java Configuration Options for HBase Master property and add the following configuration parameter:
    -javaagent:/opt/cloudera/parcels/CDH/lib/hbase/lib/trace/opentelemetry-javaagent-2.15.0.jar
  4. Locate the Java Configuration Options for HBase RegionServer property and add the following configuration parameter:
    -javaagent:/opt/cloudera/parcels/CDH/lib/hbase/lib/trace/opentelemetry-javaagent-2.15.0.jar
  5. Locate the Master Environment Advanced Configuration Snippet (Safety Valve) property and add the following environment variables:
    OTEL_METRICS_EXPORTER=prometheus
    OTEL_EXPORTER_PROMETHEUS_PORT=22005
    OTEL_EXPORTER_PROMETHEUS_HOST=127.0.0.1
    OTEL_SERVICE_NAME=hbase_master
    OTEL_TRACES_EXPORTER=none
    OTEL_LOGS_EXPORTER=none
    OTEL_INSTRUMENTATION_COMMON_DEFAULT_ENABLED=false
    OTEL_JMX_CONFIG=/opt/cloudera/parcels/CDH/etc/hbase/conf.dist/otel-agent-metrics-mapping-master.yaml
    
  6. Locate the RegionServer Environment Advanced Configuration Snippet (Safety Valve) property and add the following environment variables:
    OTEL_METRICS_EXPORTER=prometheus
    OTEL_EXPORTER_PROMETHEUS_PORT=22105
    OTEL_EXPORTER_PROMETHEUS_HOST=127.0.0.1
    OTEL_SERVICE_NAME=hbase_regionserver
    OTEL_TRACES_EXPORTER=none
    OTEL_LOGS_EXPORTER=none
    OTEL_INSTRUMENTATION_COMMON_DEFAULT_ENABLED=false
    OTEL_JMX_CONFIG=/opt/cloudera/parcels/CDH/etc/hbase/conf.dist/otel-agent-metrics-mapping-rs.yaml
    
  7. Click Save Changes.
  8. Restart the HBase service and all affected roles as prompted by Cloudera Manager.