# Send custom alert when service or CPU is idle at specific time

**URL:** <https://community.dynatrace.com/t/send-custom-alert-when-service-or-cpu-is-idle-at-specific-time/35339>\
**Category:** Alerting\
**Tags:** problem-detection, processes, problems-classic\
**Created:** [June 1, 2022, 9:17am UTC](https://community.dynatrace.com/t/send-custom-alert-when-service-or-cpu-is-idle-at-specific-time/35339 "2022-06-01T09:17:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Florian](https://avatars.discourse-cdn.com/v4/letter/f/898d66/32.png) [@Florian](https://community.dynatrace.com/u/Florian)\
**Post date:** [June 1, 2022, 9:17am UTC](https://community.dynatrace.com/t/send-custom-alert-when-service-or-cpu-is-idle-at-specific-time/35339/1 "2022-06-01T09:17:54Z")

</div>

Hello everybody,

I have a single EC2 machine which is used between 7 - 8 AM every day by a single service.

As the service on this machine runs automatically every day between that time frame, I would like to setup an alert which is sending me a hint if the process is not running between 7 and 8 AM.

Or in other words: I need an alert if the process or the CPU is idle between 7 and 8 AM.

Anybody has an idea how to configure such alerts?

I thought that maybe the anomaly detection will do this job, but that wasn’t detected somehow.

I am open for all ideas 🙂

Greetings,

Florian

---

<div class="post-metadata">

**Author:** ![jon\_kowalski](https://avatars.discourse-cdn.com/v4/letter/j/df788c/32.png) [@jon\_kowalski](https://community.dynatrace.com/u/jon_kowalski)\
**Post date:** [June 1, 2022, 7:25pm UTC](https://community.dynatrace.com/t/send-custom-alert-when-service-or-cpu-is-idle-at-specific-time/35339/2 "2022-06-01T19:25:29Z")

</div>

Hey Florian,

Narrowing down process availability monitoring to a specific time frame isn’t extremely straightforward, however, we may be able to achieve this functionality by creating a maintenance window for the process in question. Essentially we would create a maintenance window only impacting that process to “Disable problem detection during maintenance” so that the other 23 hours of the day when the EC2 isn’t running we wouldn’t alert.

After that maintenance window is created you’ll also have to enable “Process Availability Monitoring” within the Process Group settings for the process in question. This toggle will alert when monitoring is down and because we’ve configured the maintenance window, it won’t alert us that monitoring is down during the time of the day that the EC2 is not running.

Thanks.

Jon

---

<div class="post-metadata">

**Author:** ![AntonioSousa](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/antoniosousa/32/50_2.png) [@AntonioSousa](https://community.dynatrace.com/u/AntonioSousa)\
**Post date:** [June 1, 2022, 8:40pm UTC](https://community.dynatrace.com/t/send-custom-alert-when-service-or-cpu-is-idle-at-specific-time/35339/3 "2022-06-01T20:40:57Z")

</div>

[@Florian](https://community.dynatrace.com/user/49641),

As [@jon\_kowalski](https://community.dynatrace.com/user/38214) referenced, process group availability monitoring is the way to go. I have been doing with several similar use-cases. Just also leaving the documentation URL for quick reference:

> **[Process group availability monitoring and alerting](https://docs.dynatrace.com/docs/observe/infrastructure-observability/process-groups/monitoring/process-group-availability-monitoring-and-alerting)**
>
> Enable process-group availability monitoring to get alerts if processes go offline or crash.
