Modify the DNS resolution record of the domain name to resolve the website domain name to the Anti-Bot instance. This completes formal service access.
xxxxxxxxxxxxx.alicloudwaf.com
.
Instructions on CNAME configuration
If you do need to use A record resolution (for example, in cases where the @ record conflicts with the MX record), you can retrieve the allocated IP address of the Anti-Bot instance by pinging the CNAME value allocated by Anti-Bot (this IP address is invariable in normal cases). Then, configure Anti-Bot for the website domain name through A record resolution.
Instructions on domain name host records
Here, the domain name abc.com
is used as an example.
- www: is used to exactly match domain names that start with www, such as
www.abc.com
. On the contrary,abc.com
cannot be matched. - @: is used to match
abc.com
with direct access. - *: is used to match wildcard domain names, that is, any domain names, such as
blog.abc.com
,www.abc.com
, andabc.com
.
Precautions on modifying the DNS resolution record
-
Only one CNAME value can be entered for the same host record. You can change the record value to the CNAME value of Anti-Bot to configure Anti-Bot for the website domain name.
-
Different types of DNS resolution records conflict with each other, and therefore, for the same host record, the CNAME record conflicts with the A record, MX record, TXT record, and other records. For this reason, you must delete existing records before you can add a CNAME record, or change the existing record type to the CNAME type.
Note We recommend that you delete other resolution records and promptly add a CNAME record. The domain name resolution can be abnormal if the CNAME record is missing for a prolonged period after the A record has been deleted. -
If you do need to retain the MX record (mail server record), you can resolve the domain name to the IP address of the Anti-Bot instance through A record resolution. After retrieving the allocated IP address of the Anti-Bot instance by pinging the CNAME value (this IP address is invariable in normal cases), change the record value of the A record resolution type of the website domain name to the IP address of the Anti-Bot instance.Note If A record resolution is used, Anti-Bot does not support automatic faulty cluster scheduling and fault bypassing.
Procedure
This topic shows how to configure DNS in Alibaba Cloud DNS and PeanutHull. For other DNS service providers, configure DNS based on this topic.
- Log on to the Alibaba Cloud DNS console.
- Select the target domain name and click Configure in the Actions column.
- Select the target host record and click Edit in the Actions column.
Note You can also delete the existing A record and click Add Record to add a new CNAME record. Add a CNAME record as soon as possible after the existing resolution record is deleted. Otherwise, website domain name resolution may fail.
- Change the record type to CNAME, and change the record value to the CNAME value allocated by Anti-Bot.
Note We recommend that you set TTL to 600 seconds (namely, 10 minutes) for general cases. The greater the TTL value, the slower the DNS record synchronization and update.