Data configurationGrafana integrationsIntegrations referenceNomad integration

Nomad integration for Grafana Cloud

Nomad is a simple and flexible workload orchestrator to deploy and manage containers and non-containerized applications across on-prem and clouds at scale.

Install Nomad integration for Grafana Cloud

  1. In your Grafana instance, Click Integrations and Connections (lightning bolt icon), then click on install integration on Nomad tile.
  2. Wait for the integration to be installed and then follow the steps shown to setup Grafana Agent to automatically scrape and send Nomad metrics to your Cloud Instance.

Pre-install configuration for the Nomad integration

Add the stanza below in your Nomad client and server configuration files, by default it would be /etc/nomad.d/nomad.hcl:

telemetry {
  collection_interval = "1s"
  disable_hostname = true
  prometheus_metrics = true
  publish_allocation_metrics = true
  publish_node_metrics = true
}

Post-install configuration for the Nomad integration

In the agent configuration file, the agent must be pointed to each nomad server and nomad client that compose the Nomad cluster, such as nomad:4646 in the example below, that exposes a /metrics endpoint.

metrics:
  wal_directory: /tmp/wal
  configs:
    - name: integrations
      scrape_configs:
        - job_name: integrations/nomad
          metrics_path: /v1/metrics
          params:
            format: ['prometheus']
          static_configs:
            - targets: ['nomad1:4646', 'nomad2:4646', 'nomad3:4646', 'nomad-client1:4646']

Instead of using static discovery, consul service discovery can be used to discover all the nodes of the Nomad cluster:

- job_name: 'integrations/nomad'
  consul_sd_configs:
  - server: 'consul.service.consul:8500'
    services: ['nomad-client', 'nomad']
  metrics_path: /v1/metrics
  params:
    format: ['prometheus']
  relabel_configs:
  - source_labels: ['__meta_consul_tags']
    regex: '(.*)http(.*)'
    action: keep
  - source_labels: [__meta_consul_node]
    target_label: instance

Dashboards

This integration includes the following dashboards.

  • Nomad cluster
  • Nomad jobs

Nomad overview

image

Nomad jobs

image

Metrics

Below is a list of the metrics used on the dashboards and in alerts of the integration and are automatically written to your Grafana Cloud instance.

  • nomad_client_allocs_cpu_total_percent
  • nomad_client_allocs_cpu_total_ticks
  • nomad_client_allocs_memory_cache
  • nomad_client_allocs_memory_rss
  • nomad_client_host_disk_available
  • nomad_client_host_disk_inodes_percent
  • nomad_client_host_disk_size
  • nomad_client_host_memory_available
  • nomad_client_host_memory_free
  • nomad_client_host_memory_total
  • nomad_client_host_memory_used
  • nomad_client_uptime

Cost

By connecting your Nomad instance to Grafana Cloud you might incur charges. To view information on the number of active series that your Grafana Cloud account uses for metrics included in each Cloud tier, see Active series and dpm usage and Cloud tier pricing.