Cloud Monitor simulates end-user access behavior using detection points (requesters) around the globe and retrieves access data from these detection points for target URLs (monitored addresses). You can use PC-based detection to monitor your sites across Alibaba Cloud networks, carrier networks, and cloud service provider networks outside China.
Prerequisites
You have created one or more alert contacts and alert contact groups. For more information, see Create an alert contact or alert contact group.
If you want to use the alert callback feature when you configure an alert rule, you must have a callback URL that can be accessed over the Internet and enable the URL callback feature as an alert notification method in your existing O&M or notification system.
Background information
For more information about how to activate and use the site monitoring feature, see Activate Network Analysis and Monitoring.
If your site is configured with high-level firewall policy settings or a whitelist, you may need to add the IP addresses of detection points to the whitelist. This ensures that the detection points can access your site and are not blocked by the firewall. For more information, see How do I add the IP addresses of detection points to a whitelist if detection requests are identified as attacks or web scraping?
Procedure
Log on to the Cloud Monitor console.
In the left-side navigation pane, choose .
On the Monitoring Tasks tab, click Create Task and then click .
On the Create Task page, select PC and then configure the parameters for the site monitoring task.
Basic Information
Task Type: HTTP(S)
Parameter
Description
Task Name
The name of the site monitoring task. The name must be 4 to 100 characters in length and can contain letters, digits, underscores (_), and Chinese characters.
Monitored Address
The address of the site that you want to monitor. Valid values:
GET (default)
POST
HEAD
The monitored address is a URL. You can separate multiple monitored addresses with line breaks.
Frequency
The interval at which the site is monitored. Valid values: 15 seconds, 1 minute, 5 minutes, 15 minutes, 30 minutes, and 60 minutes. For example, if you select 1 minute, detection points in each region monitor the destination address once per minute. You can also customize the monitoring cycle to specify a precise monitoring time.
NoteIf you activated pay-as-you-go Cloud Monitor Basic (cms_post) or purchased subscription Cloud Monitor Basic (cms_edition) before 22:00:00 on September 13, 2022, you cannot set the monitoring frequency to 15 seconds.You must activate Network Analysis and Monitoring before you can use the 15-second monitoring frequency.
Advanced Settings
For more information about the advanced settings for HTTP(S), see Advanced settings.
ImportantHandshake protocols earlier than TLS 1.2 have security vulnerabilities. Therefore, Cloud Monitor does not support server-side TLS versions earlier than 1.2, which is consistent with mainstream browsers. If the
tls: server selected unsupported protocol version 302error is reported when a site monitoring task is running but you do not want to upgrade the TLS protocol on the server, you can select the minimum compatible TLS version on the Others tab in the Advanced Settings section.Task Type: PING
Parameter
Description
Task Name
The name of the site monitoring task. The name must be 4 to 100 characters in length and can contain letters, digits, underscores (_), and Chinese characters.
Monitored Address
The address of the site that you want to monitor. The monitored address is a domain name or an IP address. You can separate multiple monitored addresses with line breaks.
Frequency
The interval at which the site is monitored. Valid values: 15 seconds, 1 minute, 5 minutes, 15 minutes, 30 minutes, and 60 minutes. For example, if you select 1 minute, detection points in each region monitor the destination address once per minute. You can also customize the monitoring cycle to specify a precise monitoring time.
NoteIf you activated pay-as-you-go Cloud Monitor Basic (cms_post) or purchased subscription Cloud Monitor Basic (cms_edition) before 22:00:00 on September 13, 2022, you cannot set the monitoring frequency to 15 seconds.You must activate Network Analysis and Monitoring before you can use the 15-second monitoring frequency.
Number Of Ping Packets
The number of times that the ping operation is performed. Default value: 10.
Task Type: DNS
Parameter
Description
Task Name
The name of the site monitoring task. The name must be 4 to 100 characters in length and can contain letters, digits, underscores (_), and Chinese characters.
Monitored Address
The address of the site that you want to monitor. The monitored address is a domain name. You can separate multiple monitored addresses with line breaks.
Frequency
The interval at which the site is monitored. Valid values: 15 seconds, 1 minute, 5 minutes, 15 minutes, 30 minutes, and 60 minutes. For example, if you select 1 minute, detection points in each region monitor the destination address once per minute. You can also customize the monitoring cycle to specify a precise monitoring time.
NoteIf you activated pay-as-you-go Cloud Monitor Basic (cms_post) or purchased subscription Cloud Monitor Basic (cms_edition) before 22:00:00 on September 13, 2022, you cannot set the monitoring frequency to 15 seconds.You must activate Network Analysis and Monitoring before you can use the 15-second monitoring frequency.
Type
The type of the DNS query. Valid values:
A (default)
MX
NS
CNAME
TXT
ANY
AAAA
DNS Access Protocol
The protocol for DNS access. Valid values:
udp (default)
tcp
tcp-tls
DNS Server
The type of the DNS server. Valid values:
System default DNS
Carrier DNS corresponding to the detection point
Custom DNS
Number Of Retries After DNS Failure
The number of retries after a DNS detection fails.
Expected Resolution Result
Cloud Monitor verifies the domain name resolution result to check whether the result contains your expected domain name or IP address. If the expected list is a subset of the DNS list, the detection is successful.
You can separate multiple domain names or IP addresses with commas (,).
Matching Rule
The matching rule for the domain name or IP address.
DNS Server Port
The port of the DNS server.
Task Type: TCP or UDP
Parameter
Description
Task Name
The name of the site monitoring task. The name must be 4 to 100 characters in length and can contain letters, digits, underscores (_), and Chinese characters.
Monitored Address
The address of the site that you want to monitor. The monitored address is an IP address. You can separate multiple monitored addresses with line breaks.
Frequency
The interval at which the site is monitored. Valid values: 15 seconds, 1 minute, 5 minutes, 15 minutes, 30 minutes, and 60 minutes. For example, if you select 1 minute, detection points in each region monitor the destination address once per minute. You can also customize the monitoring cycle to specify a precise monitoring time.
NoteIf you activated pay-as-you-go Cloud Monitor Basic (cms_post) or purchased subscription Cloud Monitor Basic (cms_edition) before 22:00:00 on September 13, 2022, you cannot set the monitoring frequency to 15 seconds.You must activate Network Analysis and Monitoring before you can use the 15-second monitoring frequency.
Port
The port of the TCP or UDP protocol. Default value: 80.
Advanced Settings
For more information about the advanced settings for TCP or UDP, see Advanced settings.
Task Type: SMTP or POP3
Parameter
Description
Task Name
The name of the site monitoring task. The name must be 4 to 100 characters in length and can contain letters, digits, underscores (_), and Chinese characters.
Monitored Address
The address of the site that you want to monitor. The monitored address is a domain name or an IP address. You can separate multiple monitored addresses with line breaks.
Frequency
The interval at which the site is monitored. Valid values: 15 seconds, 1 minute, 5 minutes, 15 minutes, 30 minutes, and 60 minutes. For example, if you select 1 minute, detection points in each region monitor the destination address once per minute. You can also customize the monitoring cycle to specify a precise monitoring time.
NoteIf you activated pay-as-you-go Cloud Monitor Basic (cms_post) or purchased subscription Cloud Monitor Basic (cms_edition) before 22:00:00 on September 13, 2022, you cannot set the monitoring frequency to 15 seconds.You must activate Network Analysis and Monitoring before you can use the 15-second monitoring frequency.
Port
The port of the SMTP or POP3 protocol.
Default value for the SMTP protocol: 25.
Default value for the POP3 protocol: 110.
Username
The username and password of the SMTP or POP3 server.
Password
Secure Connection
Specifies whether to use a secure connection for the SMTP or POP3 protocol. Valid values:
Use
Do not use
Task Type: FTP
Parameter
Description
Task Name
The name of the site monitoring task. The name must be 4 to 100 characters in length and can contain letters, digits, underscores (_), and Chinese characters.
Monitored Address
The address of the site that you want to monitor. The monitored address is a domain name or an IP address. You can separate multiple monitored addresses with line breaks.
Frequency
The interval at which the site is monitored. Valid values: 15 seconds, 1 minute, 5 minutes, 15 minutes, 30 minutes, and 60 minutes. For example, if you select 1 minute, detection points in each region monitor the destination address once per minute. You can also customize the monitoring cycle to specify a precise monitoring time.
NoteIf you activated pay-as-you-go Cloud Monitor Basic (cms_post) or purchased subscription Cloud Monitor Basic (cms_edition) before 22:00:00 on September 13, 2022, you cannot set the monitoring frequency to 15 seconds.You must activate Network Analysis and Monitoring before you can use the 15-second monitoring frequency.
Port
The port of the FTP protocol.
Default value: 21.
Anonymous Logon
Anonymous logon (default)
Identity verification required
If you select this parameter, you must set the username and password of the FTP server.
Username
The username and password of the FTP server.
Password
Define Assertions
If you set Task Type to HTTP(S), you can use the Define Assertions feature to define availability conditions. These conditions are based on the content returned from a detection and determine whether the result meets your expectations. You can set multiple availability conditions for an assertion. The detection result is defined as available only when all conditions are met.
NoteFor HTTP detections, if you do not set an assertion for the status code, status codes less than 400 are considered available by default.
The assertion definition feature supports the HTTP(S), PING, WebSocket, DNS, TCP, and UDP protocols.
If the default availability condition provided by Cloud Monitor does not meet your requirements, perform the following steps to add a new one.
Click Add Condition Group.
Set the parameters for the availability condition of the assertion.
Response Time: determines whether the response time meets expectations. Default value: less than 5,000 ms.
Status Code: determines whether the response status code meets expectations. Default value: less than 400.
Header: determines whether the fields in the response header meet expectations. You must customize the response header.
body, XML Field Of Body, and JSON Field Of Body: determine whether the content in the returned body meets expectations through text character matching, XML parsing (XPath), and JSON parsing (JSON Path). For more information, see XPath Syntax and JSON Path Syntax.
Click Verify. You can view the verification result on the right.
If the verification is successful, you can create the site monitoring task.
If the verification fails, you can initiate a network diagnostic probe at the corresponding detection point.
If a response that does not meet the conditions is returned, you can initiate PING and My Traceroute (MTR) network diagnostic probes at the corresponding detection point.
NoteMTR is a network diagnostic tool that combines the features of PING and traceroute.
Enable Tracing Analysis: You can enable the Tracing Analysis feature as needed. This feature is supported only for HTTP(S) tasks. For more information, see Integration with OpenTelemetry.
Ingest Endpoint: Select a region based on your requirements.
Tracing Protocol: The supported protocols include
OpenTelemetry W3C,Zipkin B3, andJaeger.
Select Detection Points
Parameter
Description
IP Probe Type
The IP probe type of the detection points. This parameter can be set to IPv4, IPv6, IDC, or LastMile.
Select Detection Points
The default and custom detection points for site monitoring.
If the default detection points provided by Cloud Monitor do not meet your requirements, perform the following steps to customize detection points.
Click Manage Custom Templates.
Click Create Template.
Enter a Template Name and select custom detection points.
Click OK.
Click OK.
Configure Alert Rules
If the default alert rule provided by Cloud Monitor does not meet your requirements, perform the following steps to add a new one.
Click Add Rule.
Set the parameters for the rule description.
Parameter
Description
Rule Name
The name of the alert rule.
Metric Name
The name of the metric in the alert rule. Valid values:
Percentage of available detection points
Percentage of available detection points = (Number of times that a domain name or IP address can be normally accessed in a detection cycle/Total number of detections) × 100%.
Number of unavailable detection points
The number of unavailable detection points is the number of times that a domain name or IP address cannot be normally accessed in a detection cycle.
Number of available detection points
The number of available detection points is the number of times that a domain name or IP address can be normally accessed in a detection cycle.
Any error code (independent alert)
An alert is triggered when the detection result of any detection point matches the status code.
All error codes (combined alert)
An alert is triggered only when the detection results of all detection points match the status code.
Response time
Comparison
The comparison operator for the threshold in the alert rule. Valid values:
>=
>
<=
<
=
!=
Year-over-year increase
Year-over-year decrease
Week-over-week increase
Week-over-week decrease
Period-over-period increase
Period-over-period decrease
Threshold And Alert Level
The alert level and the corresponding threshold.
The alert notification method that corresponds to the Info alert level is Email + WebHook.
Valid values for the consecutive alert period: 1, 2, 3, 4, 5, 10, 15, and 20.
Tag
The tag of the alert rule.
Auto Scaling
If you turn on Auto Scaling, the specified scaling rule is enabled when an alert is triggered. In this case, you must configure the Region, ESS Group, and ESS Rule parameters.
For more information about how to create a scaling group, see Manage scaling groups.
For more information about how to create a scaling rule, see Manage scaling rules.
Simple Log Service
If you turn on Simple Log Service, the alert information is sent to the specified Logstore when an alert is triggered. In this case, you must configure the Region, ProjectName, and Logstore parameters.
For more information about how to create a project and a Logstore, see Use LoongCollector to collect and analyze ECS text logs.
Simple Message Queue (formerly MNS) - Topic
If you turn on Simple Message Queue (formerly MNS) - Topic, the alert information is sent to the specified topic in Simple Message Queue (formerly MNS) (SMQ) when an alert is triggered. In this case, you must configure the Region and topicName parameters.
For more information about how to create a topic, see Create a topic.
Function Compute
If you turn on Function Compute, an alert notification is sent to Function Compute for format processing when an alert is triggered. In this case, you must configure the Region, Service, and Function parameters.
For more information about how to create a service and a function, see Quickly create a function.
Click OK.
Configure Alert Contact Groups
Parameter
Description
Configure Alert Contact Groups
The alert contact groups to which alerts are sent. You must select at least one alert contact group.
Alert notifications are sent to the alert contacts in the alert contact group. An alert contact group is a group of alert contacts and can contain one or more alert contacts.
Mute Period
The interval at which an alert notification is resent after an alert is triggered but is not cleared. Valid values: 5 minutes, 15 minutes, 30 minutes, 60 minutes, 3 hours, 6 hours, 12 hours, and 24 hours.
An alert is sent when a metric reaches its threshold. If the metric continues to exceed the threshold within the mute period, no more alert notifications are sent during the mute period. If the alert is not cleared after the mute period ends, Cloud Monitor sends another alert notification.
NoteYou can click Advanced Settings to set this parameter.
Effective Period
The period during which an alert rule is in effect. The alert rule checks for monitoring data that requires an alert only within the effective period.
NoteYou can click Advanced Settings to set this parameter.
Alert Callback
The callback URL that can be accessed over the Internet. Cloud Monitor sends HTTP POST requests to push alert notifications to the specified URL. Only HTTP requests are supported. For more information about how to configure alert callback, see Use the alert callback feature to send notifications about threshold-triggered alerts.
To test the connectivity of an alert callback URL, perform the following steps:
Click Test next to the callback URL.
In the Webhook Test panel, you can check and troubleshoot the connectivity of the alert callback URL based on the returned status code and test result details.
NoteTo obtain the details of the test result, configure the Test Template Type and Language parameters and click Test.
Click Close.
NoteYou can click Advanced Settings to set this parameter.
Click Create.
Related operations
If the assertion failed message is displayed while the site monitoring task is running, it indicates that the assertion has failed. You can perform the following steps to view the cause of the failure.
On the Monitoring Tasks tab of the Site Monitoring List page, click the name of the target site monitoring task.
On the Overview page, click the Error tab in the detection results.
Click Details in the Operation column that corresponds to the target detection point to view the cause of the assertion failure.
References
Advanced settings
The following table describes the advanced settings for different monitoring types.
HTTP(S)
Tab
Parameter
Description
Request Parameters
HTTP Request Header
The format of an HTTP request header is
key1:value1. You can use line breaks to separate multiple headers. Site monitoring pre-populates the request header with the following headers:Host:${Domain name in the monitored address}Pragma:no-cacheCache-Control:no-cacheUser-Agent:Chrome/57Accept: */*
If the request content is a form, the following header is also included:
Content-Type: application/x-www-form-urlencoded;charset=UTF-8If your header contains one or more of the preceding items, these items are overwritten by your settings.
NoteBased on the HTTP protocol, the keys that you provide in the request header are converted by site monitoring to the canonical format of MIME Header:
The first letter and the letter that follows a hyphen (-) are converted to uppercase. For example, accept-encoding is converted to Accept-Encoding.
If a key contains a space or other invalid characters, the key remains unchanged.
Cookie
The cookie text of the HTTP rule.
Request Content
The format of the request content is
key1=value1;key2=value2or a JSON code snippet such as{"test":"testValue"}.NoteIf you set Request Method to POST, you must set this parameter.
Do Not Follow Redirects
Specifies whether to follow redirects for another redirection detection if the 301 or 302 status code is returned. By default, this option is not selected, which indicates that redirects are followed.
Certificate Verification
Specifies whether to support Server Name Indication (SNI). By default, this option is not selected, which indicates that SNI is not supported.
User Authentication
HTTP Authentication Username
The basic authentication through the HTTP protocol.
HTTP Authentication Password
DNS Server
DNS Server
The IP address of the DNS server.
Others
Enable ProxyProtocol
Specifies whether to enable the proxy protocol. By default, this option is not selected, which indicates that the proxy protocol is not supported.
Minimum TLS Version
The minimum TLS version that is compatible with Cloud Monitor. Valid values:
tlsv1.0tlsv1.1tlsv1.2tlsv1.3
Response Match Method
If the response content to be matched is not empty, site monitoring reads the first 64 KB of the HTTP server response body and searches for the matched response content. Valid values:
Alert if response contains matched content
Alert if response does not contain matched content
Site monitoring determines whether to trigger an alert based on the response match method.
The matched content can only be in English.
Response Content Match
Acceptable HTTP Status Code Greater Than Or Equal To 400
An HTTP status code that is greater than or equal to 400. You can separate multiple status codes with commas (,).
TCP or UDP
Parameter
Description
Request Content Format
This parameter is valid only when the request content is not empty. Valid values:
Text
Hexadecimal format
Request Content
Text
Plain text refers to a string that consists of visible characters.
NotePlain text does not support escape characters. For example, \n is treated as two characters, \ and n, instead of a line break.
Hexadecimal format
If the request content is a byte string that cannot be expressed in visible characters, you can convert the byte string into a visible string in hexadecimal format. The conversion rule is as follows: One byte is converted into a two-byte hexadecimal character. For example,
(byte)1is converted to 01 in hexadecimal format, and(byte)27is converted to 1B in hexadecimal format.A binary array in Java format, such as
{(byte)1, (byte)27}, is converted to 011b or 011B in hexadecimal format. Site monitoring is not case-sensitive to hexadecimal characters. Enter the string"011B"in the Request Content field and select Hexadecimal Format for the Request Content Format parameter.
Response Content Match Format
This parameter is valid only when the response content is not empty. Valid values:
Text
Hexadecimal format
Response Content Match
Text
Plain text refers to a string that consists of visible characters.
NotePlain text does not support escape characters. For example, \n is treated as two characters, \ and n, instead of a line break.
Hexadecimal format
If the request content is a byte string that cannot be expressed in visible characters, you can convert the byte string into a visible string in hexadecimal format. The conversion rule is as follows: One byte is converted into a two-byte hexadecimal character. For example,
(byte)1is converted to 01 in hexadecimal format, and(byte)27is converted to 1B in hexadecimal format.A binary array in Java format, such as
{(byte)1, (byte)27}, is converted to 011b or 011B in hexadecimal format. Site monitoring is not case-sensitive to hexadecimal characters. Enter the string"011B"in the Request Content field and select Hexadecimal Format for the Request Content Format parameter.