# Automatic Custom Error rule for new services

**URL:** <https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986>\
**Category:** Open Q&A\
**Tags:** services-classic, oneagent\
**Created:** [August 4, 2024, 7:19am UTC](https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986 "2024-08-04T07:19:10Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![AK](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/ak/32/164_2.png) [@AK](https://community.dynatrace.com/u/AK)\
**Post date:** [August 4, 2024, 7:19am UTC](https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986/1 "2024-08-04T07:19:10Z")

</div>

Hello Folks,

I have a requirement where we would like to set **custom error rule** to all of our services without always remembering to set it for each new service added.

Currently we need to go to _ **Failure Detection --\> General parameters --\> Custom error rules --\> Add custom error rule** _ each time for newly added services.

 ![AK_0-1722755335870.png](https://global.discourse-cdn.com/dynatrace/original/2X/c/c0fe1458da81f07b90e40b018eb61964e1b0546e.png)

Is there any way we can have this rule automatically added whenever new service get introduced in Dynatrace?

We can’t setup global rule as we have to add this rule to set of services.

Regards,

AK

---

<div class="post-metadata">

**Author:** ![AK](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/ak/32/164_2.png) [@AK](https://community.dynatrace.com/u/AK)\
**Post date:** [August 5, 2024, 1:57pm UTC](https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986/2 "2024-08-05T13:57:00Z")

</div>

Has anybody done this successfully?

Regards,

AK

---

<div class="post-metadata">

**Author:** ![Julius\_Loman](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/julius_loman/32/51_2.png) [@Julius\_Loman](https://community.dynatrace.com/u/Julius_Loman)\
**Post date:** [August 5, 2024, 2:04pm UTC](https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986/3 "2024-08-05T14:04:21Z")

</div>

Have you tried setting up failure detection rules and failure detection parameters? You can define your failure detection parameters and then specify rules to assign these setting to services.&nbsp; You can specify the rules using service tag or by management zone for example.

---

<div class="post-metadata">

**Author:** ![AK](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/ak/32/164_2.png) [@AK](https://community.dynatrace.com/u/AK)\
**Post date:** [August 6, 2024, 2:56pm UTC](https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986/4 "2024-08-06T14:56:27Z")

</div>

[@Julius\_Loman](https://community.dynatrace.com/user/3364), thanks for the response.

As per the explanation above, we have to first create the **failure detection parameters** &nbsp;and then use that parameter to define the&nbsp; **Failure detection rules** along with filter on services.

But I believe, defining **Failure detection parameters** in global setting (screenshot below) will get applied to all services present in the environment.&nbsp;Please correct me if I’m wrong.

 ![AK_1-1722955926813.png](https://global.discourse-cdn.com/dynatrace/original/3X/e/c/eca2a9a69798a16a9c6f25d8703e5ae907ab6b77.png)

Regards,

AK

---

<div class="post-metadata">

**Author:** ![AK](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/ak/32/164_2.png) [@AK](https://community.dynatrace.com/u/AK)\
**Post date:** [August 7, 2024, 3:30pm UTC](https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986/5 "2024-08-07T15:30:11Z")

</div>

Hi&nbsp;[@Julius\_Loman](https://community.dynatrace.com/user/3364), do you have any views on this

---

<div class="post-metadata">

**Author:** ![Julius\_Loman](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/julius_loman/32/51_2.png) [@Julius\_Loman](https://community.dynatrace.com/u/Julius_Loman)\
**Post date:** [August 7, 2024, 8:00pm UTC](https://community.dynatrace.com/t/automatic-custom-error-rule-for-new-services/46986/6 "2024-08-07T20:00:01Z")

</div>

[@AK](https://community.dynatrace.com/user/2080)&nbsp;no, failure detection parameters are define settings for services applied by failure detection rules. Services must match the conditions in failure detection rule to have the setting applied. The first rule gets applied.

It’s reapplied every 10 minutes, so be patient in the results.
