DNS is a "word" that we are all very familiar with, there is a DNS cache in the Windows system, and DNS resolution is the actual addressing method for most applications on the Internet. The redevelopment of domain name technology and a variety of applications based on domain name technology have enriched Internet applications and protocols, and with DNS can not only improve our Internet speed, but also improve the speed of opening web pages. However, the DNS cache is time-limited, and it will be automatically refreshed at a certain time. For example, when we visit a website for the first time, DNS will return the correct IP, and the system will temporarily store this result, which is DNS caching. The cache sets an expiration time, such as 2 hours, when we close the site after 2 hours, the system will directly return the result to you from the local DNS cache of your computer, without having to ask the DNS server, which "accelerates" the resolution of the URL in disguise. Of course, after more than N hours, the system will automatically ask the DNS server again to get new results.
By default: The default value for Windows DNS cache is MaxCacheTTL, here, it defaults to 86400s, which is a day, and macOS strictly follows the TTL in the DNS protocol!
However, unlike Windows systems, browser DNS cache time is independent of TTL, and each browser has a fixed value. The following are the cache times of common browsers:
1. Chrome Google Chrome To speed up access, Google Chrome uses the method of pre-fetching DNS records and establishing a DNS cache locally to speed up the website's connection.
chrome://net-internals/#dns 这里可以看各域名的DNS 缓存时间。Chrome对每个域名会默认缓存60s。
2. IE browser IE caches DNS for 30 minutes.
3. Firefox Firefox Firefox has a DNS caching function, but the default cache time is only 1 minute, you can change the default value to speed up DNS resolution, as follows: Open a new window, enter about:config in the address bar, enter enter, and enter the settings interface. Then search for network.dnsCacheExpiration, change the original 60 to 6000 (indicating 6000 seconds of cache), and then search network.dnsCacheEntries to change the default 20 to 1000 (for 1000 caches). If there are no above two items, you can create new them, and the new entry type is integer. Of course, you can also set other values as needed.
4. Safari is the default browser in the Apple system About 10s To ensure high availability of the service, DNS requires redundancy of multiple name servers to support each region. Resource records for a zone are manually or automatically updated on a single primary nameserver, known as the primary DNS server, which can be an authoritative nameserver for one or more zones. Parsing typically involves traversing multiple name servers to find the information you need. However, some parsers function more simply by communicating with just one name server. These simple parsers rely on a recursive name server (called a "stub parser") to find the execution work for them to find information. For example, Chrome will first make an HTTP request to the first IP, and if it doesn't work, it will make an HTTP request to the next IP Date: 2014-11-21T17:13+0800 Author: CobbLiu Org version 7.9.3f with Emacs version 24
|