CloudMonitor provides the availability monitoring feature to help you check whether a local service or cloud server responds as expected. If a local service or cloud server times out or returns an error code, CloudMonitor sends an alert notification to you.

Background information

You can create an availability monitoring task only for Elastic Compute Service (ECS), ApsaraDB RDS, and ApsaraDB for Redis.

Procedure

  1. Log on to the CloudMonitor console.
  2. In the left-side navigation pane, click Application Groups.
  3. On the Application Group tab, click the name of the application group.
  4. In the left-side navigation pane, click Availability Monitoring.
  5. Click Add availability monitoring.
  6. In the Create Task step of the Create/Modify Availability Monitoring panel, set the parameters based on your needs.
    Parameter Description
    Task Name The name of the availability monitoring task.
    Monitoring Nodes The ID of the instance that you want to monitor.
    Monitored Target The object that you want to monitor. Valid values:
    • URL or IP address: Select this option only when you need to monitor an ECS instance.
    • ApsaraDB RDS: Select this option only when you need to monitor an ApsaraDB RDS instance.
    • ApsaraDB for Redis: Select this option only when you need to monitor an ApsaraDB for Redis instance.
    Detection Type The method that you want to use to monitor the object.
    If you set the Detection Target parameter to URL or IP address, you can select one of the following methods:
    • HTTP(S): Enter the URL of the object that you want to monitor.
    • TELNET: Enter the IP address of the object that you want to monitor.
    • PING: Enter the IP address of the object that you want to monitor.
    If you set the Detection Target parameter to ApsaraDB RDS or ApsaraDB for Redis, you can select one of the following methods:
    • TELNET: Enter the instance ID and connection URL of the object that you want to monitor.
    • PING: Enter the instance ID and connection URL of the object that you want to monitor.
    Request Method The request method of the monitoring. Valid values: HEAD, GET, and POST.
    Note This parameter is required if you set the Detection Target parameter to URL or IP address and the Detection Type parameter to HTTP(S).
    Monitoring Frequency The duration of a monitoring cycle.

    Valid values: 15Second, 30Second, 1 Minutes, 2 Minutes, 5 Minutes, 15 Minutes, 30 Minutes, and 60 Minutes. For example, if you set the Monitoring Frequency parameter to 1 Minutes, CloudMonitor monitors the object once a minute.

    Note This parameter is required if you set the Detection Target parameter to URL or IP address and the Detection Type parameter to HTTP(S).
    Headers The headers of the HTTP or HTTPS request.

    Format: parameter1:value1.

    Separate multiple headers with commas (,).

    Note This parameter is required if you set the Detection Target parameter to URL or IP address and the Detection Type parameter to HTTP(S).
    POST Content The content of the POST request.

    Format: parameter1=value1&parameter2=value2. The content must be English.

    Note This parameter is required if you set the Detection Target parameter to URL or IP address, 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 to match the response content.
    If you specify response content, the monitoring task checks whether the first 64 KB of the HTTP response body contains the response content that you specify. Valid values:
    • Alert if the matching content is included.
    • Alert if the matching content not included.
    Note This parameter is required if you set the Detection Target parameter to URL or IP address and the Detection Type parameter to HTTP(S).
  7. Click Next.
  8. In the Configure Alert Rule step, set the parameters.
    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.

    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.

    Notification Methods The methods used to send alert notifications. Valid values:

    Info (Email + DingTalk)

    HTTP WebHook 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. For more information about how to configure alert callbacks, see Use the alert callback feature to send notifications about threshold-triggered alerts.
    Mute for The interval at which CloudMonitor sends alert notifications after the first alert notification is sent. Valid values: 5 Minutes, 15 Minutes, 30 Minutes, 60 Minutes, 3hour, 6hour, 12hour, and 24hour.

    If the threshold value is exceeded, CloudMonitor sends an alert notification. If the threshold value is exceeded again within the mute period, CloudMonitor does not resend an alert notification. If the alert is not cleared when the mute period elapses, CloudMonitor resends an alert notification.

    Effective Time 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.
  9. Click OK.