<>1. Three elements of network protocol

* grammar : Structure or format of data and control information .
* semantics : What kind of control information needs to be sent , What kind of action to complete and how to respond .
* synchronization : A detailed description of the order in which events are implemented .
<>2. Advantages and disadvantages of stratification

<>3. Architecture with five layer protocol

* application layer
The task is to complete the specified network application through the interaction between application processes . Application layer protocol defines the rules of communication and interaction between application processes . The data unit that the application layer interacts with is called message .
* Transport layer
The task is to provide common data transmission service for the communication between processes in two hosts .
The following two protocols are mainly used :
* Transmission control protocol TCP: Provides connection oriented , Reliable data transmission service , The unit of data transmission is the segment .
* User datagram protocol UDP: Provides connectionless , Best effort data transmission service ( The reliability of data transmission is not guaranteed ), The unit of data transmission is user datagram .
* network layer
Responsible for providing communication services for different hosts in packet switching network .
* data link layer
When data is transmitted between two adjacent nodes, the data link layer will IP It was handed over from the floor IP Datagrams are assembled into frames , Transmitting frames between two adjacent nodes . Each frame contains data and necessary control information .
The control information also enables the receiver to detect whether there is an error in the received frame , If there is a mistake, discard it .
* physical layer
The unit of data transmitted on the physical layer is bits .
be careful : It is often mentioned now TCP/IP It does not necessarily mean the two separate agreements , It's about the whole thing TCP/IP protocol family .

<>4. The process of data transmission

* The application process data is transferred to the application layer first , Add the application layer header , Become application layer PDU( Protocol data unit )
* Add the head of the transport layer to the transport layer , Become transport layer message
* Add network layer header to network layer , become IP Datagram ( Or group )
* IP Datagrams are transmitted to the data link layer , Add the head and tail of the data link layer , It becomes the data link layer frame
* The data link layer frame is then transmitted to the physical layer , The bottom physical layer carries the bit stream to the physical media .
* And then layer by layer of peeling up .
<>5. Services and agreements

* The agreement is horizontal , The protocol is the rule that controls the communication between peer entities .
* Service is Vertical , That is, services are provided from the lower layer to the upper layer through the interface between layers .