The main steps in connecting an acceleration domain name to ECDN include:
hosts
file to verify the business compatibility.
Log in to the ECDN Console and click Domain Management on the left sidebar to enter the Domain Management page. Click Add Domain Name to enter the Add Domain Name page.
On the Add Domain Name page, enter the acceleration domain name information as instructed.
Note:
- If the acceleration regions are in the mainland of China, according to relevant laws and regulations, the new acceleration domain name must have been filed on record on MIIT's ICP filing website or have obtained ICP filing through [ICP filing registration], and has not connected to Tencent Cloud CDN or ECDN before. The domain name that has been connected to the CDN needs to be deleted before being added to the ECDN platform.
- You can manage domain names by project in the Project section. Here, a project is shared by all Tencent Cloud products. You can manage projects in Project Management.
- If the origin server type is origin IP, optimal route selection, weighted, and primary/secondary origin-pull policies are supported. For more information, please see configuration methods in Advanced Origin-Pull Policies.
- If the origin server type is origin domain, you can enter only one domain name, which must be different from the acceleration domain name. You can set the port in
Host:Port
format, and the port number should be between 1 and 65535.- When you add a domain name, ECDN will display the default regular caching rules. You can modify or manage them in the rule list for customization for the domain name.
Select the transfer protocol used for communication between the edge server and origin server.
Configure caching rules for dynamic and static content of the domain name. You can use the recommended configurations by default or click Edit Caching Rule to edit the rules.
After the domain name is configured, click Submit to add it. In the pop-up box, click Go to Domain Name List to view the domain name status. After the domain name is added, the system will deploy relevant configurations on the backend, which will take effect in about 5 minutes.
To configure the domain name with HTTPS, you can do so as instructed in HTTPS Settings after adding the domain name.
hosts
To ensure continuity of access to your business, you are recommended to set the local hosts
file to verify whether access is normal before formally switching the CNAME resolution. If your page contains multiple dynamic domain names, you can add them in batches for verification
- Before verification with
hosts
, please make sure that the domain name is activated.- The CNAME address of ECDN is suffixed with
.dsa.dnsv1.com
, which can be viewed on the Domain Management page.
Run nslookup
on the local command line to resolve the ECDN CNAME domain name so as to get the IP address of the cache node.
hosts
You can configure the local hosts
file to forcibly redirect access requests to the local server to the ECDN platform, so that you can verify the platform compatibility without affecting formal access to your business.
The following uses the hosts
file on Windows as an example to show the settings. It is generally stored in C:\Windows\System32\drivers\etc\hosts
:
After setting the hosts
file, you can access resources under the acceleration domain name with a browser. The following uses Chrome as an example to show how to access the domain name:
By using the built-in packet capture tool in the browser, you can see that:
- The request address of the acceleration domain name is pointed to the ECDN node
113.107.216.105
.- The request response status code of the acceleration domain name is
200 OK
, indicating that user requests can be responded to normally, which meets the test expectation.- If the response status code of the acceleration domain name is exceptional, you can submit a ticket. Please attach screenshots of your operations in the ticket to facilitate troubleshooting.
hosts
file is passed, you can forward requests to the domain name to the ECDN acceleration platform. You need to complete the CNAME configuration at your DNS service provider of the acceleration domain name. For more information on how to configure a CNAME record, please see CNAME Record Configuration.ping
or dig
command to check whether the CNAME record is in effect. If a domain name suffixed with .dsa.sp.spcdntip.com
or .dsa.p23.tc.cdntip.com
is returned, the CNAME record has taken effect.When the distribution is completed, ECDN will allocate a corresponding CNAME address to you, which needs to be configured before the acceleration service taking effect. For detailed directions, please see CNAME Configuration.
Was this page helpful?