Encapsulation encapsulation refers to the process of adding Additional Protocol header information to the data prior to transmission.In the vast majority of data communication processes, the source data will be encapsulated in a number of protocols before transmission.
When a message is sent over the network. The protocol stack on the host operates from top to bottom.
In the case of network server, the HTTP Application layer protocol sends HTML-formatted Web page data to the transport layer, and the application layer data is divided into TCP segments. Each TCP segment is labeled. Called the header, which indicates to which process the receiver should receive this message. The same time also includes information that allows the recipient to reorganize the data according to the original format.
The transport layer sends the Web page HTML data to the network layer and runs the IP layer protocol.
The entire TCP segment is encapsulated as an IP packet, which is the IP header tag. The IP header includes the source and destination IP addresses, as well as the information necessary to send the message to the destination address.
After that, the IP packets are sent to the access layer, encapsulated with a frame header and a frame tail. Each frame header includes a source and destination physical address.
The physical address uniquely specifies a device on the local network. The end of the frame includes error correction information. Finally, the server NIC transmits the bit encoding to the media.