Overview
Motadata AIOps introduces rule-based tagging, a feature designed to automate the assignment and removal of tags across various monitored entities, including Monitors, VMs, Applications, Processes, Services, IP SLA, and Interfaces. This functionality eliminates the manual effort traditionally required for tag management.
Rule-based tagging supports the application of static tags, key-value pair tags, and dynamic tags. Furthermore, it allows mulitple metric counter-based conditions. These conditions enable the precise application or removal of tags based on specific performance metrics, ensuring tags are applied only to devices that meet the defined criteria.
Navigation
Go to Menu. Select System Settings . After that, select Rule Based Tags. The configuration page for Rule Based Tags is now displayed.
Rule Based Tags Screen
You shall be able to view all the configured rules for tagging on this screen. Below is a gist for all the fields available:
Field | Description |
---|---|
Rule Name | Name of the rule. |
Description | Description can contain either the purpose of the rule, types of devices it applies the tag |
Operation | Displays if the rule is being used to assign or remove tags. |
Used Count | The Used Count column will display the total number of devices which are associated with the rule. |
Tag | This column will display the tag which will be assigned or removed using the particular rule. |
Last Ran At | Displays the timestamp of when the rule was executed. |
Actions | Below are the actions available for a rule: - Click on - Click on |
Deleting a Rule will not remove all the Tags that have been applied using the specific rule. In order to remove the tags associated with the deleted rule, you will need to create a new rule to remove the tags.
Create a Rule
Click on the Create Rule option in the top right of the screen to start creating your custom Rule to automatically tag the devices. On the Create Rule screen, below configuration options will be available:
Field | Description |
---|---|
Rule Name | Enter the name of the rule. |
Description | Enter information to explain the purpose of the rule or mention on what devices it will applicable. |
Rule Applies to | Select a type of device using the monitor. |
Tag Operation | Select Assign or Remove opeartion to perform the respective action using the rule. |
Key | Specify the tag you want to assign. You can choose to a define a standalone tag or a key-value pair based tag. In case you are defining a key-value pair based tag, populate the value field as well. |
Value | Value field allows to define static and dynamic tags. Mention the tag to define a static value. For dynamic tags, mention the counter name inside curly brackets {} (refer to the note below). |
Condition | Check Configuring Condition section to know more about it. |
To define a dynamic tag, mention the complete counter name inside the curly brackets {}
. (For e.g. {instance.type}
)
Configuring Condition
You can specify multiple conditions based on metric counters that will ensure the filters are assigned or removed when the conditions are met. The condition block allows you to define multiple conditions.
Since there are multiple parameters that you can set, let's look at them individually:
Field | Description |
---|---|
Group Matching | This option will help you define if you want to include or exclude the devices matching the condition you have defined. Below is a gist: - Include: When selected, will include all the devices that match the defined condition. - Exclude: When selected, will exclude all the devices that match the defined conditions. |
Counter | Mention the metric counter you want to set as the condition. |
Operator | Select an operator from the dropdown. |
Value | Enter the value that you want to equate against the metric counter. |
AND/OR | This option will help you define intra-condition operation. Below is gist of the available options: - AND: When selected, tag will only apply to the devices satisfying both the conditions. - OR: When selected, tag will only apply to the devices satisfying either of the conditions. |
Click on to add more conditions.
Rule Criteria
Rule Criteria will display the Rule Condition query in raw format in real-time. It will help you understand how the query is formed and executed in the backend.
- Click on Create Rule to apply the configuration and save.
- Click on Preview to see the list of devices that qualify for the defined rule condition.
- Click on Reset to clear all fields and start afresh.
Use-Case
For instance, you want to assign a Tag Environment:Prod
to monitor having type as Linux that contains prod
in its name. Let's understand the configuration required to achieve the above scenario.
Once you have provided the Rule name and description, ensure you select Monitor under the Rule applies to dropdown. The next step would be to choose Assign Tag under the Tag Operation field.
After that, mention Environment
in the Key field and Prod
in the Value field.
Now, the conditions will need to be configured to assign the tags only to Linux monitors containing prod
in its name.
Select Include operation for Group Matching. Then, select object.type
using the Counter field and choose Contains in the Operator dropdown. Finally, enter Linux
in the Value.
Click on to add one more condition. Then select AND operator between two conditions.
Now, select object.name
using the Counter dropdown and choose Contains as the Operator. Then, enter prod
as Value.
You shall also be able to see the generated query under the Rule Criteria section.
Click on Preview to view the list of devices qualifying for the rule.
Click on Create Rule to apply and save the configuration.