This topic describes how to modify the DNS server configuration for a domain in the Alibaba Cloud Domain Names console. A DNS server is responsible for responding to DNS queries for your domain. Modifying this configuration affects DNS resolution for your domain.
Before you begin
To prevent service interruptions when you modify the DNS servers, you must first synchronize your DNS records.
-
Synchronize DNS records: In your target DNS provider's console, add your domain and configure all necessary DNS records.
-
Verify resolution: Query the new DNS server directly to verify that it responds correctly.
# Replace yourdomain with your domain. # Replace ns1.alidns.com with the address of the target DNS server. dig @ns1.alidns.com yourdomain A dig @ns1.alidns.com yourdomain MX -
Check and disable DNSSEC (skip this step if not configured)
If your domain has DNSSEC (Domain Name System Security Extensions) enabled, you must first go to your domain registrar to delete the DS records and disable DNSSEC.
# Use the dig command to check the DNSSEC status of your domain. # If the response includes an RRSIG record, DNSSEC is enabled. dig +dnssec yourdomain.com -
(Recommended) Lower the TTL: To reduce propagation time and shorten rollback times, we recommend lowering the TTL (Time-To-Live) value for critical DNS records, such as A and MX records. Set the TTL to a low value, such as 300 or 600 seconds, 24 to 48 hours before you modify the DNS servers. Wait for the old TTL period to expire before performing the modification.
Procedure
Modify DNS servers for a single domain
-
Log on to the Domain Names page. Find the domain you want to manage and click Manage in the Actions column.
-
In the navigation pane on the left, choose .
-
On the DNS Server Change page, click Change DNS Server.
-
Enter the target DNS server addresses and click OK.
Modify DNS servers for multiple domains
-
Log on to the Domain Names page, select multiple domains, and then click at the bottom of the page.
-
On the DNS Server Change page, enter the the addresses of your Custom DNS servers. Then, submit the change and complete the SMS verification.
-
On the Bulk Operations Log details page, verify that the operation was successful.
Verify the change
After submitting the change, run the following commands to monitor the propagation status.
# Replace yourdomain with your domain.
# 1. Check whether the NS records at the registry have been updated to the new DNS server addresses.
dig yourdomain NS
# 2. Trace the full resolution path to confirm that requests are ultimately answered by the new DNS servers.
dig +trace yourdomain A
Production environment considerations
-
Perform this operation during off-peak hours and prepare a rollback plan.
-
After modifying the DNS servers, propagation time depends on the TTL of the domain's NS records cached by local DNS resolvers. The changes can take up to 48 hours to fully propagate worldwide.
FAQ
What is a domain's DNS server?
A domain's DNS server stores and manages information for that domain in the Domain Name System. These servers hold various records for the domain, such as A records (which map a domain to an IPv4 address), AAAA records (which map a domain to an IPv6 address), MX records (which specify the mail servers for the domain), and CNAME records (which create an alias for a domain).
After registering a domain, you must configure its DNS servers so that other computers on the internet can find the IP address and other information associated with it. Typically, you can use the default DNS servers provided by your domain registrar, or set up your own DNS servers for greater control over your DNS configuration.
For example, if you own the domain example.com and set its DNS servers to ns1.example.com and ns2.example.com, DNS resolvers worldwide will query these specific servers for records related to example.com or its subdomains (like www.example.com). This process allows users to access your website, email services, and other resources.
To ensure high availability and redundancy, configure at least two DNS servers. This way, if one server becomes unavailable, the other can serve as a backup to prevent service interruptions.
Is my domain using Alibaba Cloud DNS?
Alibaba Cloud authoritative DNS server addresses:
|
Edition |
DNS server name |
|
Paid Edition |
vip(1-8).alidns.com |
|
Free Edition |
dns(1-32).hichina.com, ns(1-8).alidns.com |
Method 1:
-
Log on to the Domain Names page. Find the domain and click Manage in the Actions column.
-
In the navigation pane on the left, choose .
-
On the DNS Server Change page, check whether the currently configured DNS server addresses are Alibaba Cloud DNS server addresses.
Method 2:
-
Use a WHOIS query tool, enter the domain, and then click Query Now.
-
Check whether the DNS Server addresses are Alibaba Cloud DNS server addresses.
If you are not using Alibaba Cloud DNS servers and want to switch, see Procedure.
Why can't I modify DNS servers?
You cannot modify DNS settings if a domain is in a grace period or redemption period, or is undergoing a transfer. To modify the DNS settings, you must first renew the domain or wait for the transfer to complete. For more information about how to renew a domain, see Domain Renewal.
Why are DNS changes not taking effect?
This issue is usually caused by one of the following reasons:
-
Incorrect configuration on new DNS servers: This is the most common reason. Log on to your new DNS provider's console and verify that all necessary DNS records (such as A, CNAME, and MX records) have been added for the domain.
-
Local DNS cache: DNS resolvers in your region or on your personal device might have cached the old NS records. DNS changes can take up to 48 hours to propagate globally. You can wait for the cache to expire or try flushing your local DNS cache.
-
Self-managed DNS issues: If you use a self-managed DNS server, check that your server firewall allows traffic on port 53, the DNS service is running correctly, and the authoritative zone is configured correctly.
Can I use multiple DNS providers?
This depends on your domain registrar. If the registrar's console allows you to enter DNS server names from multiple providers, then it is possible. Domains registered with Alibaba Cloud support specifying DNS server addresses from different providers simultaneously.
Why do DNS modifications fail?
-
The modification will fail if the specified DNS servers are invalid.
-
The domain is locked. A registrar lock prevents DNS server modifications. You can use a WHOIS query to check the domain status. If the domain is locked, the Domain Name Status field may show "clientUpdateProhibited" or a similar status indicating updates are prohibited by the registrar.
Solution:
-
Log on to the Domain Names page. Find the domain and click Manage in the Actions column.
-
In the navigation pane on the left, click Security Settings.
-
Find the Update Lock item, click Disable, and complete the required security verification.
-
How can I find my local DNS server?
The following steps are for Windows:
-
Open Command Prompt. You can find it by searching for "cmd" or "Command Prompt" in the Start menu.
-
Enter
ipconfig /alland press Enter. -
In the output, find the "DNS Servers" line. The listed addresses are your DNS servers.
Access issues despite correct DNS resolution
If domain resolution is working correctly but you cannot access an overseas server, the issue is likely a network connectivity problem, not a DNS configuration error. Common reasons include:
-
Cross-border network link limitations: When you access overseas servers from the Chinese mainland, network traffic must pass through cross-border links. Connectivity to some overseas IP addresses or ports may be unstable due to network congestion or policy adjustments.
-
Source IP restrictions on the target server: Some overseas servers are configured to restrict access from specific regions, resulting in connection timeouts or rejections.
-
Local network or firewall blocking: Your corporate intranet firewall, security group policies, or local ISP may restrict outbound traffic.
Troubleshooting methods:
-
First, use
digornslookupto confirm that the domain resolves to the correct target server IP address. If the resolution is incorrect, follow the procedure in this topic to modify your DNS servers or contact your DNS provider for assistance. -
If resolution is correct, use
traceroute(on Linux/macOS) ortracert(on Windows) to trace the network path to the target IP address and identify any packet loss or high-latency nodes. -
If the cross-border link is persistently unstable, consider using a cross-border network optimization solution such as Alibaba Cloud Global Accelerator (GA).
How to clear the local DNS cache?
Yes, your computer has a local cache. The following steps are for clearing the cache on Windows:
-
Open Command Prompt as an administrator. You can do this by searching for "cmd" or "Command Prompt" in the Start menu, right-clicking it, and selecting "Run as administrator".
-
Enter
ipconfig /flushdnsand press Enter. -
If the command is successful, you will see a message that says "Successfully flushed the DNS Resolver Cache."