After adding and configuring the domain in the CDN console, it is recommended to perform testing and validation. If the access is normal, switch DNS resolution to Tencent Cloud. The test methodology is as follows. For more details, see CDN Access Test.
1. View the CNAME domain, which is www.qcdntest.cn.cdn.dnsv1.com.cn
.
2. Obtain the CDN node IP
Open the terminal command window and execute the following command in the command line: the returned IP is the CDN acceleration node.
ping www.qcdntest.cn.cdn.dnsv1.com.cn
.
3. Set the hosts file
Bind the node IP (110.185.117.235) obtained in step 2 and the acceleration domain name (www.qcdntest.cn) to the local computer hosts file. The filling method is IP domain name, with the IP address first, followed by the acceleration domain name, separated by a space.
Windows system: the hosts file path location is C:\Windows\System32\drivers\etc\hosts. Bind as shown in the figure below.
.
macOS system: Enter the terminal (command window), type sudo vi /etc/hosts, press Enter, then enter the password, and press Enter again to open the hosts file. After entering, type i to edit. The filling method is the same as the above Windows system.
4. Conduct a simulated access test. If the response is consistent with the origin server, it indicates access successful.