# OS services monitoring for all services other than X Y Z

**URL:** <https://community.dynatrace.com/t/os-services-monitoring-for-all-services-other-than-x-y-z/46853>\
**Category:** Alerting\
**Tags:** services-classic, problems-classic\
**Created:** [July 28, 2024, 8:07am UTC](https://community.dynatrace.com/t/os-services-monitoring-for-all-services-other-than-x-y-z/46853 "2024-07-28T08:07:45Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yosi\_Neuman](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/yosi_neuman/32/9845_2.png) [@Yosi\_Neuman](https://community.dynatrace.com/u/Yosi_Neuman)\
**Post date:** [July 28, 2024, 8:07am UTC](https://community.dynatrace.com/t/os-services-monitoring-for-all-services-other-than-x-y-z/46853/1 "2024-07-28T08:07:45Z")

</div>

Hi guys,

Customer asks to check if all services are in running status except of 3 services.

With in the _Detection rules_&nbsp;we can set positive $or for more than one service.

![Yosi_Neuman_1-1722154754225.png](https://global.discourse-cdn.com/dynatrace/original/3X/f/1/f12077af7b551dc89cf5de90c1bf716e55c6a759.png)

But when adding $not in order to negate those services we get syntax error

 ![Yosi_Neuman_0-1722154731178.png](https://global.discourse-cdn.com/dynatrace/original/3X/0/0/00cd0b5d41392b5853d3b6bd356aca80ba5a46fc.png)

Also $not to $and is not acceptable and showing syntax error

 ![Yosi_Neuman_3-1722154912757.png](https://global.discourse-cdn.com/dynatrace/original/3X/3/d/3de2961bf0b5198fa0823c1e9780ceb5ae6f90e6.png)

Any suggestion on how to fulfill this request will be appreciate.

Thanks in advance

Yos

---

<div class="post-metadata">

**Author:** ![Esam\_Eid](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/esam_eid/32/167_2.png) [@Esam\_Eid](https://community.dynatrace.com/u/Esam_Eid)\
**Post date:** [July 28, 2024, 9:46am UTC](https://community.dynatrace.com/t/os-services-monitoring-for-all-services-other-than-x-y-z/46853/2 "2024-07-28T09:46:22Z")

</div>

it seems the AureAttestService & webClient are two different services, so i believe you have to create two different rules

---

<div class="post-metadata">

**Author:** ![Yosi\_Neuman](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/yosi_neuman/32/9845_2.png) [@Yosi\_Neuman](https://community.dynatrace.com/u/Yosi_Neuman)\
**Post date:** [July 28, 2024, 9:57am UTC](https://community.dynatrace.com/t/os-services-monitoring-for-all-services-other-than-x-y-z/46853/3 "2024-07-28T09:57:10Z")

</div>

Hi&nbsp;[@Esam\_Eid](https://community.dynatrace.com/user/65475)

Thanks for your suggestion, may be I didn’t not explain my self clearly hence I will try again what is our goal here:

We are looking for alert on **ALL** services beside those 2 services …

In other words we want to get alert if any service beside those 2 is not in running mode.

Tanks

Yos

---

<div class="post-metadata">

**Author:** ![Esam\_Eid](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/esam_eid/32/167_2.png) [@Esam\_Eid](https://community.dynatrace.com/u/Esam_Eid)\
**Post date:** [July 28, 2024, 11:19am UTC](https://community.dynatrace.com/t/os-services-monitoring-for-all-services-other-than-x-y-z/46853/4 "2024-07-28T11:19:25Z")

</div>

Hi&nbsp;[@Yosi\_Neuman](https://community.dynatrace.com/user/6931)&nbsp;,

i just created the below rule to test. the first one should be used if you want to exclude any of the services.

Second one if you want to include everything under monitoring, you just add any prefix which will never match any service name.

after testing i could see the alerts triggered for all stopped services.

 ![Esam_Eid_0-1722165424184.png](https://global.discourse-cdn.com/dynatrace/original/3X/9/f/9ffe7f35e762db148333699ff3f97c8c978e28a9.png)

---

<div class="post-metadata">

**Author:** ![Yosi\_Neuman](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/yosi_neuman/32/9845_2.png) [@Yosi\_Neuman](https://community.dynatrace.com/u/Yosi_Neuman)\
**Post date:** [July 28, 2024, 11:54am UTC](https://community.dynatrace.com/t/os-services-monitoring-for-all-services-other-than-x-y-z/46853/5 "2024-07-28T11:54:53Z")

</div>

Thanks&nbsp;again&nbsp;[@Esam\_Eid](https://community.dynatrace.com/user/65475)&nbsp;for your efforts and investigation.

Understood from your answer that we need rule for each negate

Test it also and its look working

Thanks!

Yos
