---
title: "Error when trying to configure a rule"
description: "Rule configuration errors occur due to syntax issues, invalid paths, or missing references. Solutions include correcting code syntax, verifying path aliases, and ensuring active times exist in the rule settings."
url: "https://docs.itrsgroup.com/docs/faq/geneos/4407627806097-geneos-error-when-trying-to-configure-a-rule/index.html"
---
## Related to

Rule error, validation error, problem saving config, setup error, unable to save config, rule set up.

### Problem

There are many possible causes why you are getting a rule error when saving or validating Gateway configuration. In this article, we summarize some of the common error messages seen.

### Possible Cause(s)

**Error Message 1** - *The rule ‘Rule – <rule name>’ contains syntax errors in the code block.*

**Error Message 2** - *Absolute/Relative secondary variables should not contains wildcards - only the first data-item returned will be used. To remove this warning, use the 'first' function in conjunction with a wpath to get the first matching item.*

**Error Message 3** - *'schemas' : Unmatched child node. Perhaps the nodes are in the wrong order, or the node is invalid at this location.*

**Error Message 4** - *Ignored target for rule '<rule name>' as xpath contains non-identifying predicate.*

**Error Message 5** - *Ignored rule '<rule name>’: pathAlias '<path alias name>' does not exist.*

***Error Message 6** -* *Rule ‘<rule name> references non-existent ActiveTime ‘<active time name>’, removing the ActiveTime.*

### Possible Solution(s)

**Solution Error Message 1** - Common syntax errors are caused by misspellings, unexpected tokens, or missing operands.

The syntax of the If...then...elseif...else statement is as follows:

```
if value > replaceWithValue then
severity critical
elseif value > replaceWithValue then
severity warning
else
severity ok
endif
```

Useful tool: When configuring a rule, you can right click anywhere on the rule code block, select **Templates > If...then...elseif...else** to obtain the rule template.

**Solution Error Message 2** - please click [here](https://docs.itrsgroup.com/docs/faq/geneos/115004032369-geneos-how-to-fix-warning-absolute-relative-secondary-variables-should-not-contains-wildcards-only-the-first-data-item-returned-will-be-used-when-saving-gateway-configuration/index.html) for details.

**Solution Error Message 3** - please click [here](https://docs.itrsgroup.com/docs/faq/geneos/360002531438-geneos-schemas-unmatched-child-node-perhaps-the-nodes-are-in-the-wrong-order-or-the-node-is-invalid-at-this-location/index.html) for details.

**Solution Error Message 4** - please click [here](https://docs.itrsgroup.com/docs/faq/geneos/115004023585-geneos-gateway-what-does-the-warning-message-ignored-target-for-rule-rule-name-as-xpath-contains-non-identifying-predicate-mean/index.html) for details.

**Solution Error Message 5** - Make sure the path alias referenced in the rule block is present.

**Solution Error Message 6** - Make sure the active time referenced in the Advanced tab of the rule is present.

## Related Articles

- [Gateway, Rules, Actions & Alerts](https://docs.itrsgroup.com/docs/geneos/current/processing/monitoring-and-alerts/geneos_rulesactionsalerts_tr/index.html#Heading-introduction)
- [How do I fix "WARNING Absolute/Relative secondary variables should not contains wildcards - only the first data-item returned will be used..." when saving Gateway configuration](https://docs.itrsgroup.com/docs/faq/geneos/115004032369-geneos-how-to-fix-warning-absolute-relative-secondary-variables-should-not-contains-wildcards-only-the-first-data-item-returned-will-be-used-when-saving-gateway-configuration/index.html)
- ['schemas' : Unmatched child node. Perhaps the nodes are in the wrong order, or the node is invalid at this location?](https://docs.itrsgroup.com/docs/faq/geneos/360002531438-geneos-schemas-unmatched-child-node-perhaps-the-nodes-are-in-the-wrong-order-or-the-node-is-invalid-at-this-location/index.html)
- [What does the warning message "Ignored target for rule '<rule name>' as xpath contains non-identifying predicate" mean?](https://docs.itrsgroup.com/docs/faq/geneos/115004023585-geneos-gateway-what-does-the-warning-message-ignored-target-for-rule-rule-name-as-xpath-contains-non-identifying-predicate-mean/index.html)


