tcp+ip+http+ Ethernet Protocol +socket++ (Overview)

Source: Internet
Author: User

These things will not be confused, because they are not a level of East, now think about the early I feel some do not understand because the agreement is in the abstraction layer is not clear, the knowledge should be from the bottom solid walk.

First, the agreement is not big, the agreement is the two sides agreed to abide by the norms, only that. The data transmission between the Internet is on the Ethernet, and it needs to do some processing before it is placed on the ethernet, assuming we want to send an HTTP request header, the HTTP request header is applied, and we have spelled out a request for HTTP according to the specification of the HTTP protocol. After we spell it, we need to put this on the Ethernet to send it to another computer, but we can't just say something to the Ethernet, why? Because the data to who use must know the target application of the port, so we also need a protocol to encapsulate this data for him to add port information, so UDP and TCP out, TCP is only the enhanced version of UDP is to add a port to the data, but TCP in the information transmission of the reliability of a lot of work, For example, in the preparation of the transmission phase he will be three times with the target host handshake, said is the handshake is I pass you the data back, to ensure that we all pass, and then to send the application layer want to transmit data, each transmission will wait for the other side of the answer, said that has been successfully sent, or need to resend again, The end is also a process of mutual communication, although the implementation of a reliable but inefficient, TCP protocol for the data after the port data can be transferred? Or not. The port does not have IP data to the Ethernet is nowhere to go, so the IP protocol came out, IP protocol to this data processing, plus the IP information can be dropped to Ethernet, then this can always be transferred? Or not, the maximum length of the Ethernet packet is 1500 bytes, if the IP packet exceeds this size we need to cut it apart, plus the Ethernet header, to facilitate the reorganization of the receiver data, and then this data can be started. At the end of the socket, the socket is a TCP or UDP implementation, that is, we have a protocol, always need a program to implement this Protocol in order to use it in programming, socket is such a program.

tcp+ip+http+ Ethernet Protocol +socket++ (Overview)

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.