After you set up an Anti-DDoS Pro or Anti-DDoS Premium instance to protect your website service by using a domain name, you must modify the DNS records of the domain name to reroute the traffic directed to your website to the instance. The instance scrubs the traffic and then forwards the traffic to the origin server. This topic describes how to modify the CNAME record of a domain name. In this example, the DNS resolution service is provided by Alibaba Cloud DNS.

Prerequisites

  • An Anti-DDoS Pro or Anti-DDoS Premium instance is set up by using a domain name. For more information, see Step 1: Add forwarding rules.
  • The back-to-origin IP addresses of instances are added to the whitelist of the origin server. If you deploy third-party security software on your origin server, such as a firewall, add the back-to-origin IP addresses to the whitelist of the security software. For more information, see Allow back-to-origin IP addresses to access the origin server.
  • The traffic forwarding settings take effect. Before you switch service traffic to Anti-DDoS Pro or Anti-DDoS Premium, we recommend that you verify that the instances can forward inbound traffic to the origin server on your local machine. For more information, see Verify the forwarding configuration on your local machine.

Background information

In the following example, the domain name is managed by Alibaba Cloud DNS.

Note Alibaba Cloud DNS provides basic DNS services for free and offers other value-added services in the paid edition. If you activated the value-added services of Alibaba Cloud DNS in the paid edition for your website, we recommend that you enable NS Mode Access to reroute traffic to Anti-DDoS Pro or Anti-DDoS Premium. For more information, see Enable NS Mode Access to protect a website.

If you use third-party DNS services, log on to the system of the DNS provider to modify the DNS records. The following example is for reference only.

Assume that the domain name of your website associated with an instance is bgp.ddostest.com. The following procedure describes how to modify and add DNS records in the Alibaba Cloud DNS console.

Procedure

  1. Log on to the Alibaba Cloud DNS console.
  2. On the Manage DNS page, find the domain name ddostest.com and click Configure in the Actions column.DNS records
  3. On the DNS Settings page, find the A record or CNAME record whose Host is bgp and click Edit in the Actions column.
    Note If you cannot find the DNS record that you want to manage in the list, you can click Add Record to add the record.
    Modify the record
  4. In the Edit Record or Add Record dialog box, set Type to CNAME and change Value to the CNAME record assigned by Anti-DDoS Pro or Anti-DDoS Premium.Modify the record
  5. Click OK and wait for the settings to take effect.

What to do next

Step 3: Configure protection policies