Experience in switching website primary domain names
I. Overview
The previous Domain Name of the website is XXX. Com. This name is not easy to read. I want to rename it XXX. Com.
Ii. Experience Summary
1. If you want to perform smooth (Seamless) Switching without feeling it, you need to have an idea: the New and Old services run simultaneously, and then remove the previous services to achieve the purpose of replacement.
For details, the old domain name corresponds to dns, cdn, and a core Nginx proxy server. At this time, two cdns must be used at the same time, and two core Nginx proxies must be used at the same time, one is for the old domain name and the other is for the new domain name. Then replace it with the old domain name.
Note: It is complicated because the situation is complicated and there is no need to clearly record it. You just need to sum up your ideas. The two services can be used at the same time to achieve seamless switching.
To put it simply, when two domain names were used at the same time, one was redirected to the other. Now two domain names were used at the same time, and the other was redirected to the other. Therefore, dns will have a refresh synchronization time during the switchover, so that both domain names can be used at the same time, and the old and new domain names must be available in real time.
2. the dns will be cached after modification. Remember that all dns configurations are cached, including Domain Name Redirection, host ns pointing, and A or cname pointing. In addition, the jump has the highest priority, followed by the ns record, which is A or cname. That is to say, if all these configurations are configured and conflict occurs, the highest priority will take effect.
3. Several commands:
3.1 view domain name ns records
Nslookup
Set type = ns
Www.baidu.com
3.2 view domain name jump information and header information
Curl-I www.baidu.com
Because the above information is cached, it is not necessarily real-time information. Therefore, you must use commands to direct to the 8.8.8.8 Domain Name Server.