Define custom metrics for an alert condition

Admins or Owner

To alert on custom metrics, follow standard procedures to add a condition to an alert policy. The condition's Thresholds section includes the option to select Custom > Search metric name, where you will define your specific metric values. You can start typing the custom metric name or select from the list that automatically appears.

Requirements for custom metrics

Use the alert policy's Thresholds section to define the custom metric values. These include:

  • The exact custom metric name for the selected product category and targets
  • Selected threshold value; for example, average, minimum, maximum, count, or rate
  • Selected threshold level; for example, above, below, or equal to
  • Critical (required) and Warning (optional) threshold duration values that trigger the alert; for example, 5 units for at least 5 minutes
  • Condition name (required) for the custom metric

Create a custom metric condition

Admins or Owner

To define the custom metric values for your alert policy:

  1. Go to alerts.newrelic.com > Alert policies, then select an existing policy, or add a new alert policy.
  2. From the policy's Alert conditions page, select Add a condition.
  3. From the Categorize section, select the product and type of condition for the custom metric.
  4. From the Select targets section, add one or more targets (entities) that use your custom metric.
  5. From the Define thresholds > When target application: section, select Custom > Search metric name, and begin typing the custom metric name or select from the list. Then provide the required threshold values for your custom metric.
  6. From the Define thresholds > Condition name section, provide a meaningful freeform condition name for your custom metric, maximum 100 characters.
  7. Optional: Include the URL with runbook instructions for handling the situation.
  8. Select Create condition.

Repeat these steps as needed to create additional conditions using custom metrics.

View or update custom metric conditions

Admins or Owner

After you save the condition, New Relic Alerts shows the selected alert policy's Alert conditions page with a list of each condition. From here you can follow standard procedures to select and update the custom metric condition.

The Condition name does not appear in the Thresholds section for a saved condition. If you want to change the condition name for a custom metric, edit it from the selected policy's Alert conditions page:

  1. Go to alerts.newrelic.com > Alert policies > (select a policy) > Alert conditions.
  2. Mouse over the condition's name on the list so the edit [pencil] icon appears. Then type a meaningful freeform name.

Custom metric examples for alert notifications

If you have created a plugin or custom dashboard for your custom metric, you can view your custom metric name there. For other ideas about how to apply custom metrics (for example, to alert on received and transmitted network stats), visit the New Relic Online Technical Community.

For more help

Recommendations for learning more: