Skip to content

Alibaba Cloud CDN

Performance metrics display for Alibaba Cloud CDN, including requests per second, downstream traffic, edge bandwidth, response time, back-to-origin bandwidth, status codes, etc.

Configuration

Install Func

It is recommended to enable the Guance integration - extension - hosted version Func

If you deploy Func by yourself, refer to Self-deployed Func

Enable Script

Note: Please prepare an Alibaba Cloud AK that meets the requirements in advance (for simplicity, you can directly grant global read-only permission ReadOnlyAccess)

Hosted Version Enable Script

  1. Log in to the Guance console
  2. Click on the 【Integration】 menu and select 【Cloud Account Management】
  3. Click 【Add Cloud Account】, choose 【Alibaba Cloud】, fill in the required information on the interface; if cloud account information has been configured before, ignore this step
  4. Click 【Test】, after a successful test click 【Save】, if the test fails, check whether the relevant configuration information is correct and retest
  5. Click on the 【Cloud Account Management】 list to see the added cloud account, click on the corresponding cloud account to enter the details page
  6. Click the 【Integrate】 button on the cloud account details page, find Alibaba Cloud CDN under the Not Installed list, click the 【Install】 button, and install it from the pop-up installation interface.

Manual Enable Script

  1. Log in to the Func console, click 【Script Market】, enter the official script market, search: guance_aliyun_cdn

  2. After clicking 【Install】, input the corresponding parameters: Alibaba Cloud AK ID, AK Secret, and account name.

  3. Click 【Deploy Startup Script】, the system will automatically create a Startup script set and automatically configure the corresponding startup script.

  4. After enabling, you can see the corresponding automatic trigger configuration in 「Management / Automatic Trigger Configuration」. Click 【Execute】 to immediately execute once without waiting for the scheduled time. Wait a moment, then you can view the execution task records and corresponding logs.

We default collect some configurations, see the Metrics section for details.

Configure custom cloud object metrics

Verification

  1. Confirm in 「Management / Automatic Trigger Configuration」 whether the corresponding tasks have the corresponding automatic trigger configurations. You can also check the task records and logs for any abnormalities.
  2. In Guance, 「Infrastructure / Custom」, check if there are asset information.
  3. In Guance, 「Metrics」, check if there are corresponding monitoring data.

Metrics

After configuring Alibaba Cloud - Cloud Monitor, the default metric set is as follows. You can collect more metrics through configuration Alibaba Cloud Cloud Monitor Metric Details

Metric Id Metric Name Dimensions Statistics Unit
BPS Bandwidth Peak userId,instanceId Average,Minimum,Maximum bits/s
BPS_isp Edge Network Bandwidth(isp) userId,instanceId,protocol,continent,country,province,isp Value bits/s
EsCode4xx EdgeScript Rule Exception Count userId,instanceId Sum Count
EsCode4xxRatio EdgeScript Rule Exception Ratio userId,instanceId Value %
GroupBPS (Group Dimension) Bandwidth Peak userId,groupId Sum bits/s
GroupInternetOut (Group Dimension) Downstream Traffic userId,groupId Sum bytes
InternetOut Downstream Traffic userId,instanceId Average,Maximum,Minimum bytes
InternetOut_isp Downstream Traffic(isp) userId,instanceId,protocol,continent,country,province,isp Value bytes
QPS Requests Per Second userId,instanceId Average,Minimum,Maximum Count
QPS_isp Requests Per Second(isp) userId,instanceId,protocol,continent,country,province,isp Value Count
UserQPS User-Dimension Edge QPS userId Average count
Usercode4xx User-Dimension Edge Status Code 4XX Ratio userId Average %
Usercode5xx User-Dimension Edge Status Code 5XX Ratio userId Average %
UserhitRate User-Dimension Edge Hit Rate userId Average %
code1xx Edge Status Code 1XX Ratio userId,instanceId Maximum %
code1xx_isp Edge Status Code 1XX Ratio(isp) userId,instanceId,protocol,continent,country,province,isp Value %
code2xx Edge Status Code 2XX Ratio userId,instanceId Maximum %
code2xx_isp Edge Status Code 2XX Ratio(isp) userId,instanceId,protocol,continent,country,province,isp Value %
code3xx Edge Status Code 3XX Ratio userId,instanceId Maximum %
code3xx_isp Edge Status Code 3XX Ratio(isp) userId,instanceId,protocol,continent,country,province,isp Value %
code4xx Edge Status Code 4XX Ratio userId,instanceId Average,Minimum,Maximum %
code4xx_isp Edge Status Code 4XX Ratio(isp) userId,instanceId,protocol,continent,country,province,isp Value %
code5xx Edge Status Code 5XX Ratio userId,instanceId Average,Minimum,Maximum %
code5xx_isp Edge Status Code 5XX Ratio(isp) userId,instanceId,protocol,continent,country,province,isp Value %
code_count_499 Edge Status Code 499 Count userId,instanceId Average,Maximum,Minimum count
code_count_499_isp Edge Status Code 499 Count(isp) userId,instanceId,protocol,continent,country,province,isp Value Count
code_ratio_1 (Deprecated) Edge Status Code 1XX Ratio userId,domain_name Maximum %
code_ratio_2 (Deprecated) Edge Status Code 2XX Ratio userId,domain_name Maximum %
code_ratio_3 (Deprecated) Edge Status Code 3XX Ratio userId,domain_name Maximum %
code_ratio_499 Edge Status Code 499 Ratio userId,instanceId Average,Maximum,Minimum %
code_ratio_499_isp Edge Status Code 499 Ratio(isp) userId,instanceId,protocol,continent,country,province,isp Value %
hitRate Edge Byte Hit Rate userId,instanceId Average,Maximum %
l1_acc Edge Accumulated Request Count userId,instanceId Maximum,Average,Minimum count
l1_acc_isp Edge Accumulated Request Count(isp) userId,instanceId,protocol,continent,country,province,isp Value Count
ori_acc Back-to-Origin Accumulated Request Count userId,instanceId Maximum,Average,Minimum count
ori_bps Back-to-Origin Network Bandwidth userId,instanceId Maximum,Average,Minimum bits/s
ori_code_ratio_1xx Back-to-Origin Status Code 1XX Ratio userId,instanceId Maximum,Average,Minimum %
ori_code_ratio_2xx Back-to-Origin Status Code 2XX Ratio userId,instanceId Maximum,Average,Minimum %
ori_code_ratio_3xx Back-to-Origin Status Code 3XX Ratio userId,instanceId Maximum,Average,Minimum %
ori_code_ratio_499 Back-to-Origin Status Code 499 Ratio userId,instanceId Maximum,Average,Minimum %
ori_code_ratio_4xx Back-to-Origin Status Code 4XX Ratio userId,instanceId Maximum,Average,Minimum %
ori_code_ratio_5xx Back-to-Origin Status Code 5XX Ratio userId,instanceId Maximum,Average,Minimum %
rt Edge Response Time userId,instanceId Maximum,Average,Minimum milliseconds
rt_isp Edge Response Time(isp) userId,instanceId,protocol,continent,country,province,isp Average,Maximum,Minimum milliseconds
user_code_count_499 User-Dimension Edge Status Code 499 Count userId Average,Maximum,Minimum %

Objects

Data structure of collected Alibaba Cloud SLB objects, which can be seen in 「Infrastructure - Custom」

{
  "measurement": "aliyun_cdn",
  "tags": {
    "name"          : "xxxxx.com",
    "CdnType"       : "web",
    "DomainName"    : "xxxxx.com",
    "DomainStatus"  : "online",
    "SslProtocol"   : "on",
    "CertName"      : "xxxxx.com",
    "Status"        : "success",
    "CertType"      : "free",
    "CertDomainName": "xxxxx.com",

  },
  "fields": {
    "CertExpireTime": "2022-12-13T16:00:00Z",
    "GmtCreated"    : "2022-12-13T16:00:00Z",
    "message"       : "{Instance JSON Data}"
  }
}

Feedback

Is this page helpful? ×