If a local service times out or returns an error code, CloudMonitor sends an alert notification to you.
Prerequisites
- The CloudMonitor agent is installed on the host that you want to monitor. This is required because the availability monitoring of a local service depends on the CloudMonitor agent. For more information, see Install and uninstall the CloudMonitor agent for C++.
- One or more application groups are created. For more information, see Create an application group.
Procedure
- Log on to the CloudMonitor console.
- In the left-side navigation pane, click Application Groups.
- On the Application Groups tab, click the name of the application group.
- In the left-side navigation pane, click Availability Monitoring.
- Click CreateAvailability Monitoring Task.
- In the Create/Modify Availability Monitoring Task panel, configure parameters for the task.
Parameter Description Task Name The name of the availability monitoring task. Monitoring Nodes The IDs of the instances that you want to monitor. Detection Target The object that you want to monitor. Set the Detection Target parameter to URL or IP Address.
Detection Type The method that you want to use to monitor the object. You can select one of the following methods: - HTTP(S): Enter the URL of the object. Format:
http://localhost:port/path
. Set the Request Method parameter to HEAD, GET, or POST. - TELNET: Enter the IP address of the object. Format:
127.0.0.1:port
. - PING: Enter the IP address of the object.
For example, to check whether Apache Tomcat responds as expected, select HTTP(S) and enter
http://localhost:8080/monitor
. To check the connectivity of a MySQL database, select TELNET and enter127.0.0.1:3306
.Request Method The request method. Valid values: HEAD, GET, and POST. Note This parameter is required only if you set the Detection Type parameter to HTTP(S).Monitoring Frequency The interval at which detection requests are sent. Valid values: 15 Seconds, 30 Seconds, 1 Minute, 2 Minutes, 5 Minutes, 15 Minutes, 30 Minutes, and 60 Minutes. For example, if you select 1 Minute, CloudMonitor sends a detection request to the monitored object every minute.
Note This parameter is required only if you set the Detection Type parameter to HTTP(S).Headers The HTTP or HTTPS headers of detection requests for site monitoring. A header must be in the
parameter1:value1
format.Separate multiple headers with commas (,).
Note This parameter is required only if you set the Detection Type parameter to HTTP(S).POST Content The content of POST requests for site monitoring. The content must be in the
parameter1=value1¶meter2=value2
format and must be in English.Note This parameter is required only if you set the Detection Type parameter to HTTP(S) and the Request Method parameter to POST.Match Response Content The response content that you want to match and the method that you want to use to match the response content during site monitoring. If you specify response content, the site monitoring task checks whether the first 64 KB of the body of the HTTP response contains the response content that you specify. Valid values:- Generate Alerts If Response Contains
- Generate Alerts If Response Does Not Contain
Note This parameter is required only if you set the Detection Type parameter to HTTP(S). - HTTP(S): Enter the URL of the object. Format:
- Click Next.
- In the Configure Alert Rule step, configure parameters for the alert rule.
Parameter Description Status Code If the status code reaches the specified value, an alert is triggered.
An alert is triggered regardless of which value of the Status Code parameter or the Response Time parameter reaches the threshold. CloudMonitor sends alert notifications to the alert contact group of the application group.
Response Time If the response time reaches the specified value, an alert is triggered.
If the value of the Status Code parameter or the Response Time parameter meets the threshold value, an alert is triggered. CloudMonitor sends alert notifications to the alert group of a specified application group.
Notification Methods The alert level and the methods that are used to send alert notifications. Valid values: Info (Email +Webhook)
Alert Callback The URL that is used to receive the alert notifications sent from CloudMonitor by using HTTP POST requests. The URL must be accessible over the Internet. You can enter only an HTTP URL. Mute For The interval at which CloudMonitor sends alert notifications until the alert that is triggered based on the alert rule is cleared. Valid values: 5 Minutes, 15 Minutes, 30 Minutes, 60 Minutes, 3 Hours, 6 Hours, 12 Hours, and 24 Hours. If the conditions of an alert rule are met, an alert is triggered. CloudMonitor does not resend an alert notification when the alert is triggered within the mute period. If the alert is not cleared after the mute period ends, CloudMonitor resends alert notifications.
Effective Period The validity period of the alert rule. The system sends alert notifications only within the validity period of an alert rule and records events when the validity period expires. - Click OK.