This topic describes how to enable the global acceleration feature in the Log Service console.

Prerequisites

  • Log Service is activated. A project and a Logstore are created. For more information, see Create a project and a Logstore.
  • Dynamic Route for CDN (DCDN) is activated. For more information, see Activate Dynamic Route for CDN.

    DCDN provides the HTTP acceleration and HTTPS acceleration features. Before you enable the HTTPS acceleration feature, enable the HTTP acceleration feature.

Enable the HTTP acceleration feature

  1. Log on to the DCDN console.
  2. In the left-side navigation pane, click Domain Names.
  3. On the Domain Names page, click Add Domain Name.
  4. On the Add Domain Name page, configure the parameters as described in the following table.
    Domain Name to Accelerate
    Parameter Description
    Domain Name to Accelerate The domain name that is used to accelerate data transmission. The domain name is in the project_name.log-global.aliyuncs.com format. Replace project_name with your actual project name.
    Business Type Select Dynamic Acceleration.
    Origin Information Type Select Site Domain.
    Domain Name Enter the public domain name of the project. For more information, see Service endpoint.
    Port Select Port 80.
    Acceleration Region
    • If you select Mainland China Only or Global, you must apply for an Internet Content Provider (ICP) filing from the Ministry of Industry and Information Technology (MIIT) of China. For more information, see Domain filing.
    • If you select Global (Excluding Mainland China), an ICP filing is not required.
  5. Click Next.
    On the Domain Names page, you can view the CNAME of the added domain name.Domain Names
  6. Enable the global acceleration feature in the Log Service console.
    1. Log on to the Log Service console.
    2. In the Projects section, click the target project.
    3. On the Overview page, click Modify on the right of Global Acceleration.
    4. In the Global Acceleration dialog box, enter the CNAME of the domain name, and click Enable Acceleration.
      Enable the global acceleration feature
  7. Verify the configurations of the global acceleration feature.

    After you complete the configurations, you can access the domain name for acceleration to check whether the configurations take effect. For example, if the global acceleration feature is enabled for the test-project project, you can run the curl command to send a request to the domain name for acceleration. The following response indicates that the acceleration configurations take effect:

    $curl test-project.log-global.aliyuncs.com
    {"Error":{"Code":"OLSInvalidMethod","Message":"The script name is invalid : /","RequestId":"5B55386A2CE41D1F4FBCF7E7"}}

Enable the HTTPS acceleration feature

After the HTTP acceleration feature is enabled, you can enable the HTTPS acceleration feature based on your business requirements.

  1. Log on to the DCDN console.
  2. In the left-side navigation pane, click Domain Names.
  3. Find the target domain name, and click Configure in the Actions column.
  4. In the left-side navigation pane, click HTTPS Settings.
  5. On the page that appears, click Modify in the SSL Certificate section.
  6. In the HTTPS Settings dialog box, configure the required parameters, and click OK. The following table describes the required parameters.
    Parameter Description
    SSL Acceleration Turn on the SSL Acceleration switch.
    Certificate Type Select Free Certificate, and select Agree to grant Alibaba Cloud permission to apply for a free certificate.

    For more information about the HTTPS acceleration feature, see Configure an SSL certificate.

FAQ

What do I do if the error project not exist prompts when I access a domain name for acceleration?

The possible cause of the error project not exist is that the configured origin site is incorrect. In the DCDN console, enter the public domain name of the project. For more information about domain names, see Service endpoint.
Note The change in the origin domain name takes effect several minutes later.

What to do next

After you enable the global acceleration feature for the target project, you can also configure the feature for Logtail or SDK-based log collection.
  • Use Logtail to collect logs
    • If the global acceleration feature is enabled before the Logtail installation, select Global Acceleration when you install Logtail. For more information, see Install Logtail in Linux.
    • If the global acceleration feature is enabled after the Logtail installation, follow the instructions in this topic to switch the Logtail collection mode to Global Acceleration. For more information, see Configure Logtail collection acceleration.
  • Use an SDK to collect logs

    If you use an SDK to collect logs, you can replace the endpoint of the Log Service project that is configured in the SDK with log-global.aliyuncs.com.