Skip to main content

Enterprise Server 3.20 is currently available as a release candidate.

Using Grafana to analyze OpenTelemetry metrics

Monitor the health and performance of your instance using dashboards and metrics provided by the OpenTelemetry metrics stack.

Prerequisites

OpenTelemetry metrics must be enabled on the instance. For configuration instructions, see Configuring OpenTelemetry for your instance.

  1. From an administrative account on GitHub Enterprise Server, in the upper-right corner of any page, click .
  2. If you're not already on the "Site admin" page, in the upper-left corner, click Site admin.
  3. In the " Site admin" sidebar, click Management Console.
  4. If you have created multiple Management Console user accounts, select Root site admin or Management Console user. For more information about Management Console user accounts see, Managing access to the Management Console.
  5. Type your Management Console credentials. Then click Continue.
  6. Click the Monitor tab.

Metric labels

The OpenTelemetry stack exporters automatically attach labels to metrics. Common labels are:

  • job — the name of the exporter that produced the metric
  • instance — the instance name from which the metric originated

For some exporters (like node_exporter or haproxy_exporter), open-source documentation may be available by searching for the job label value.

Label availability varies by exporter and metric. Some GitHub application-level metrics may provide fewer labels than infrastructure/exporter metrics, and labels are subject to change from version to version.

Inspecting panel queries

Important

Pre-built dashboards can be opened and edited for inspection, but changes cannot be saved. Create a copy of a dashboard to apply and retain any customizations.

To understand which metrics and queries power a given panel, use the graph panel menu (3 vertical dots) when viewing a Grafana dashboard:

  • Edit: Opens the panel editor. This is the most direct way to review and adjust the queries that power the visualization.
  • Explore: Opens Grafana Explore with the panel’s queries pre-populated, allowing interactive analysis.
  • Metrics Drilldown: Opens a side panel for discovering related metrics and breaking down the metric by label values.

Exploring metrics in Grafana

Grafana provides multiple ways to discover and analyze the metrics available on your instance.

Grafana Drilldown

Grafana Drilldown provides a guided workflow to discover metrics by filtering on metric prefixes, labels, and label values. After selecting a metric, Grafana can break down the series by available label values. For example, haproxy_backend_response_errors_total can be grouped by proxy/back-end label values.

Grafana Explore

Grafana Explore enables interactive analysis using PromQL (Prometheus Query Language), including a query builder that can help users discover available metrics and labels.

Tips for working in Grafana Explore:

  • Use Code mode's Metric browser to discover metrics and labels. Selecting labels and label values can reveal associated metrics, and selecting a metric can reveal associated labels and label values.
  • After selecting a metric, switch to Builder mode for suggestions to refine the query.
  • Access additional operations via the + Operations button.
  • Customize legend labels in the Options panel using the Legend setting, for example false. By default, Grafana assigns legend labels based on unique label sets.

Further reading