Scenarios
Intelligent DNS resolution applies to the following scenarios:
Cross-carrier or cross-region access within China: Most online applications use IP addresses from multiple carriers. Traditional Domain Name System (DNS) resolution returns one of these IP addresses at random or based on simple rules. This can result in slow access speeds or a poor user experience for users on different networks or in different regions. You can configure intelligent DNS resolution to route users to the nearest access point.
Intelligent access for global businesses: For global businesses, application services are often deployed in multiple regions, such as in China and outside China, to ensure a high-quality access experience for all users. You can configure intelligent DNS resolution to route users to the appropriate access point based on their location.
Restricted access from specific carriers or regions: Some applications may need to restrict access from specific carriers or regions. For example, you may need to block access from users outside China. You can configure intelligent DNS resolution to meet this requirement.
Preparations
Cross-carrier or cross-region access within China
A domain name for user access, such as example.com. This topic uses the Alibaba Cloud DNS Ultimate Edition as an example.
Three carrier IP addresses: 1.1.XX.XX (China Unicom), 2.2.XX.XX (China Mobile), and 3.3.XX.XX (China Telecom).
Intelligent access for global businesses
A domain name for user access, such as example.com. This topic uses the Alibaba Cloud DNS Ultimate Edition as an example.
Two server IP addresses: 1.1.XX.XX (outside China) and 2.2.XX.XX (China Telecom).
Restricted access from specific carriers or regions
A domain name for user access, such as example.com. This topic uses the Alibaba Cloud DNS Ultimate Edition as an example.
One server IP address: 2.2.XX.XX (China Telecom).
Configuration method
Cross-carrier or cross-region access within China
This configuration has the following effects: Alibaba Cloud DNS intelligently identifies the source of the visitor and returns the corresponding IP address.
If a visitor's local DNS has an egress IP address from China Mobile, the DNS query returns 2.2.XX.XX.
If a visitor's local DNS has an egress IP address from China Telecom, the DNS query returns 3.3.XX.XX.
If a visitor's local DNS has an egress IP address that is not from China Telecom or China Mobile, such as from Dr. Peng or China Unicom, the DNS query returns 1.1.XX.XX.
Configuration method
On the Alibaba Cloud DNS - Authoritative Domain Names page, click the target domain name to open the Settings page.
Click the Add Record button. Add records for the subdomain
test.example.comto point to the three carrier IP addresses: 1.1.XX.XX (China Unicom), 2.2.XX.XX (China Mobile), and 3.3.XX.XX (China Telecom). Set Query Source to Default, China Mobile, and China Telecom for the respective records.
Intelligent access for global businesses
This configuration has the following effects:
If a visitor's local DNS has an egress IP address from outside China, the DNS query returns 1.1.XX.XX.
If a visitor's local DNS has an egress IP address from within China, the DNS query returns the China Telecom IP address 2.2.XX.XX.
Configuration result
Restricted access from specific carriers or regions
This configuration has the following effects:
If a visitor's local DNS has an egress IP address from outside China, the DNS query returns 127.0.0.1. This address prevents users outside China from accessing the service.
If a visitor's local DNS has an egress IP address from within China, the DNS query returns the China Telecom IP address 2.2.XX.XX.
