Eight Mistakes in Domain Name Resolution

original
2012/07/30 08:15
Reading number 1.1K

DNS resolution is generally to provide the mapping of domain name to IP address, for example, www.google.com resolves to 74.125.71.103. There are at least two necessities for this. First, IP addresses are hard to remember, while domain names are easier to remember; Second, the virtual host based on the host header needs to use the domain name to identify different service contents.

Some webmasters will have some unreasonable requirements when resolving domain names, which is mainly caused by the wrong understanding of DNS. The following are some common domain name resolution errors.

1. Please parse example. com: 8080
DNS resolution does not include ports, so in the DNS system, only the mapping of example.com to an IP address can be provided, and the latter port cannot be processed. If you want the browser to automatically jump to port 8080 when visiting example.com, please configure the rewrite of the web server.

2. Please resolve host_a.example.com
This is an invalid domain name. The domain name cannot contain underscores. It can be letters, numbers, or dashes.
There is a category of domain names that can contain underscores (SVR records), which is not within the scope of discussion.

3. Please parse example host
This can be a host name, but it is not a valid domain name and cannot be resolved in DNS.
Please configure in your hosts file.

4. After setting the domain name resolution, you can ping, but the website still cannot be opened
In fact, this is not related to DNS. It is likely that the virtual host on the web server has not been opened yet.
For example, if example.com resolves the IP address of a host company, the host company needs to open a virtual host for the domain name to access it.

5. When visiting www.a.com, automatically jump to www.b.com
This is also not a domain name resolution category. Please configure the rewrite of the web server to achieve this.

6. Please analyze http://example.com/path/ To an IP address
This is a complete URL, not a domain name. The domain name only includes example.com.
If you want to route based on the request path, for example,/bbs/to one host,/news/to another host, configure a web server or proxy server. For example, Squid's ACL based on the request path can do this well.

7. example.com resolves to two IP addresses, A and B, so that A can get more access
DNS polling is balanced and there is no weight setting. In fact, this cannot be done.
Software with load balancing function, such as LVS and Nginx, can do this.

8. Domain name resolution should take effect immediately
For standard DNS systems such as DNSbed, the new domain name takes effect immediately.
How long the changed domain name takes effect depends on the TTL settings of the old domain name.
For example, for the domain name example.com, the previous TTL is 600 seconds. After the domain name is changed, it will take up to 600 seconds for the domain name to take effect globally.

Expand to read the full text
Loading
Click to lead the topic 📣 Post and join the discussion 🔥
Reward
zero comment
three Collection
one fabulous
 Back to top
Top