This is the multi-page printable view of this section. Click here to print.

Return to the regular view of this page.

Export telemetry to Grafana Cloud

    This tutorial shows you how to export metrics from your Datum platform to Grafana Cloud using an ExportPolicy and Secret.

    Before you begin

    This tutorial assumes you have already:

    Overview

    You will configure metric export by:

    1. Accessing your Grafana Cloud instance
    2. Generating Prometheus remote write configuration
    3. Creating Datum Secret and ExportPolicy resources

    The process extracts connection details from Grafana Cloud’s generated configuration and creates the necessary Datum resources automatically.

    Step 1: Access your Grafana Cloud instance

    If you don’t have a Grafana Cloud account, create one at grafana.com.

    1. Sign in to Grafana Cloud
    2. Navigate to your desired instance
    3. Copy your instance URL (for example: https://play.grafana.net)

    Step 2: Generate connection URL

    Use this form to generate the Grafana Cloud connection URL:

    Grafana Cloud Connection URL Generator

    Step 3: Get Prometheus configuration

    1. Click the generated connection URL above
    2. Choose whether to create a new API token or use an existing one
    3. Complete the form and submit it
    4. Copy the generated Prometheus configuration YAML

    The configuration looks similar to this:

    remote_write:
      - url: https://prometheus-prod-56-prod-us-east-2.grafana.net/api/prom/push
        basic_auth:
          username: 123456
          password: glc_eyJvIjoiNzA2...
    

    Step 4: Generate and apply Datum resources

    Paste your Prometheus configuration below to generate the Secret and ExportPolicy. Use the tabs to choose between applying from stdin or saving to files:

    Datum Resource Generator

    Secret

    Provide your Prometheus configuration above to generate the Secret manifest

    ExportPolicy

    Provide your Prometheus configuration above to generate the ExportPolicy manifest

    Step 5: Verify the configuration

    Check that your resources were created successfully using the names you specified:

    Verify the Secret:

    kubectl get secret grafana-cloud-credentials

    Verify the ExportPolicy:

    kubectl get exportpolicy export-datum-telemetry

    Step 6: View your metrics

    You can view your metrics in Grafana Cloud by visiting the Metrics Drill Down app at the link below:

    Enter your Grafana Cloud instance URL in Step 2 above to generate the metrics link

    Alternatively, you can access your metrics through your Grafana Cloud instance’s Explore section or create custom dashboards to visualize the data.

    Troubleshooting

    If metrics aren’t appearing in Grafana Cloud:

    1. Check Secret encoding: Ensure username and password are correctly base64 encoded
    2. Verify endpoint URL: Confirm the Prometheus remote write endpoint is accessible
    3. Review ExportPolicy: Check that the metricsql selector matches your services
    4. Check authentication: Verify your API token has write permissions for Prometheus

    For additional help, consult the Grafana Cloud documentation.