1. The browser checks the DNS cache to find the IP address of the domain name. To find the DNS record, the browser checks the following four caches:
  • Step 1: Check the browser cache, because the browser maintains DNS records of sites you visited during a previous period
  • Step 2: Check the operating system cache. If it is not found in the browser cache, the browser will call the underlying computer’s operating system to retrieve the record
  • Step 3: Check the route cache. If no record is found on your computer, the browser will communicate with the route that maintains its own DNS cache
  • Step 4: to check if the ISP caching, before a few steps have failed, the browser will turn to the Internet service provider, ISP maintains his own DNS servers (this is the last to find where you request URL address cache) (ISP: Internet service providers 】 【 cache for adjusting the network traffic and improve data transmission time plays an important role 】

If it is not found in the cache, the ISP’s DNS server launches a DNS query to find the IP address of the host (such as www.baidu.com) server. The DNS resolver usually finds the corresponding IP address through recursive or iterative search. After finding the IP address, the DNS resolver sends the IP address to your browser. After receiving the IP address, the browser initiates a TCP connection with the server. When the browser receives the correct IP address, the client establishes a connection with the server through a TCP/IP three-way handshake. The server matches the IP address and sends the message. TCP/IP three-way handshake: – Step 1: The client sends the SYN (serial number synchronization) to the server over the Internet to check whether the server is developing a new connection – Step 2: If the service has a developed port that can accept and start a new connection, the server responds by using an determinate status response of the SYN packet in the SYN/ACK packet (both SYN/ ACKS are sent to the client, ACK: the acknowledgment character) – Step 3: The client sends a SYN/ACK packet from the server and sends the ACK packet to the server to confirm acceptance of the data. 3. After the TCP connection is established, the browser sends an HTPP request to the Web server. 4. The server processes the request and returns an HTTP response. 5. The browser displays the content of the server response in HTML and displays it

  • Note: Domain name resolution and TCP connections take place at the TCP/IP application layer, and HTTP transfers take place at the TCP/IP transport layer. What the TCP/IP network layer does is to look up the routing table and route requests from clients through multiple routers to the server.