Create Custom Alerts in Dynatrace: A Step-by-Step Guide
Monitoring without meaningful alerts is like flying blind. Dynatrace offers powerful observability, but its true strength lies in how you configure alerts to catch anomalies before they become incidents. In this blog, we’ll walk through how to create custom alerts using Metric Events in Dynatrace, perfect for cloud-native environments, SREs, and DevOps teams.
What Are Custom Alerts in Dynatrace?
Custom alerts allow you to define thresholds on specific metrics. When those thresholds are breached, Dynatrace triggers an alert tied to the violating component. This gives you precise control over what matters most in your environment.
Example: You might want to trigger an alert when CPU usage exceeds 85% on a critical service for more than 5 minutes.
Step-by-Step: Creating a Custom Alert
1. Navigate to Metric Events
2. Select Your Metric Key
- Use the metric key search bar to find the metric you want to monitor (e.g., CPU usage, Response time, Error rate)
- Choose the appropriate entity type (e.g., Host, Service, Process Group)
3. Define Alert Conditions
- Using the Entity filter and Dimension filter select a specific host, process or , service
- Set the threshold (e.g., CPU > 85%)
- Choose the sliding window or evaluation window (e.g., over 5 minutes)
- Define violating samples (e.g., 3 out of 5 samples must breach the threshold)
4. Configure Event Details
- Name your alert in the Title (e.g., “High CPU on Payment Service”)
- Add a meaningful description, like threshold has been breached
- Add Property and provide key and value (Eg, Alert team and Alerting Profile Name)
5. Set Up Alert Routing
- Go to Settings → Alerting → Alerting Profiles
- Link your custom event to the right alerting profile
- Configure notification channels (email, Slack, webhook, etc.)
6. Tag-Based Filtering (Optional but Powerful)
Use tags to scope alerts to specific environments, teams, or services
Example: Only alert on services tagged with env:prod and team:payments