TCP basic and TCP connection status

Source: Internet
Author: User


TCP is a connection-oriented, reliable, and byte-stream-based Transport layer communication protocol. In the simplified computer network OSI model, it completes the functions specified by the layer-4 transport layer. TCP (Transmission Control Protocol) is an industrial standard Protocol set designed for Wide Area Network (WANs. It was developed by research institutions of the ARPANET network. Protocol 1. TCP connection status the TCP connection status is divided into 12 types: ESTABLISHED, SYS_SENT, SYN_RECV, FIN_WAIT1, FIN_WAIT2, TIME_WAIT, CLOSED, CLOSED, LAST_ACK, LISTEN, CLOSEING, and UNKNOWN. In many cases, no 12th types are added. In fact, it also belongs to the TCP connection status. 2. Establish a connection over TCP (three handshakes over TCP) 1. first, the Client sends a request with the syn sign to the Server and waits for the Server's response. 2. after receiving the request from the Client, the Server immediately responds to the response packet with the syn ack flag on the Client side (the state in netfilter has been recorded as ESTABLSHED ). Www.2cto.com 3. After the Client receives a response, it sends an ack package to the Server. At this time, the establishment is complete and normal communication can be performed. The connection status becomes TCP's ESTABLSHED. 3. TCP termination 1. The Client sends an end request packet with the fin flag to the Server. 2. After receiving the request, the Server responds to the response packet with ack from the Client, and then sends the end request packet with fin. 3. After receiving the request, the Client also responds to the response packet with ack. The TCP connection is interrupted.
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.