CloudMonitor supports monitoring on Elastic Compute Service (ECS) instances and third-party hosts. This topic describes how to configure an alert rule to monitor an ECS instance. In this example, the CPU Utilization metric is specified as the alert condition for the alert rule.
Prerequisites
An ECS instance is created. For more information, see Creation methods.
An alert contact group is created. For more information, see Create an alert contact or alert contact group.
Step 1: Check whether the CloudMonitor agent is installed on the host
After you create an ECS instance in the ECS console, the host is displayed in the Host Monitoring list of the CloudMonitor console. Before CloudMonitor can monitor an ECS instance, you must install the CloudMonitor agent on the ECS instance.
Check whether the CloudMonitor agent is installed on the ECS instance that you created.
If the CloudMonitor agent is installed, perform Step 2: Create an alert rule for the host.
If Running is displayed in the argusagent Status column of the ECS instance, the CloudMonitor agent is installed.
If the CloudMonitor agent is not installed, manually install the CloudMonitor agent on the ECS instance. For more information, see Automatic installation (recommended).
If Reinstall/Upgrade is displayed in the argusagent Status column of the ECS instance, the CloudMonitor agent is not installed.
Log on to the CloudMonitor console.
In the left-side navigation pane, click
.For more information about monitoring of third-party hosts, see Install and uninstall the CloudMonitor agent.
For more information about how to delete third-party hosts from host monitoring, see What do I do If a third-party host fails to be deleted from the Host Monitoring list?
Step 2: Create an alert rule for the host
When you view the metrics for the ECS instance, you can create an alert rule for the ECS instance. If the value of the specified metric meets the specified alert condition, an alert is triggered and CloudMonitor sends an alert notification. This helps you monitor the metric status in real time.
On the Host Monitoring page, click the name of the host that you want to manage.
On the Host Monitoring Details page, click the
icon in the CPU Utilization(%) section.
In the Configure Rule Description panel, enter a rule name in the Alert Rule field, configure the Metric Type, Metric, and Threshold and Alert Level parameters, and then click OK.
Alert level
Default alert notification method
Critical
Email + Webhook
Warn
Email + Webhook
Info
Email + Webhook
In the Create Alert Rule panel, specify an alert contact group. Use the default values for other parameters.
NoteIf an alert contact is configured with only an email address or webhook URL, the alert contact can receive alert notifications only by using emails or webhooks.
Click Confirm.
For information about how to modify, disable, enable, and delete an alert rule, see Manage alert rules.
Log on to the CloudMonitor console.
In the left-side navigation pane, click
.For more information about how to configure an alert rule, see Create an alert rule.
Step 3: View host alerts
After an alert rule is created, you can perform the following operations to view the alert rule and alert status.
In the left-side navigation pane, choose .
On the Alert Rules page, view the required alert rule and alert status.
If the status of the alert rule is Normal, no alert is triggered.
If the alert rule is in the Alert state, alerts are triggered and alert notifications are already sent. You can also view the historical alerts of the alert rule. For more information, see View historical alerts.
Log on to the CloudMonitor console.