Things you should know about OSI and TCP/IP

Open System Interconnection OSI

OSI definition

OSI is the abbreviation of Open System Interconnection, translated as "Open System Interconnection".
The OSI model divides the work of network communication into 7 layers, from bottom to top they are the physical layer, data link layer, network layer, transport layer, session layer, presentation layer and application layer.
The OSI seven-layer model is a theoretical model, and practical applications are ever-changing. Therefore, it is more used as the basis for analyzing and judging various network technologies; for most applications, only its protocol family (ie protocol stack) and seven The layer model corresponds roughly to see whether the specific protocol actually used belongs to a certain sublayer of the seven layers, or whether it includes the functions of the upper and lower layers.
Insert picture description here
Picture from the Internet

Application Layer

An interface between network services and end users.
Protocols are: HTTP FTP TFTP SMTP SNMP DNS TELNET HTTPS POP3 DHCP

Presentation Layer

Data representation, security, and compression.
Formats include JPEG, ASCll, EBCDIC, encryption format, etc.

Session Layer

Establish, manage, and terminate sessions.
Corresponding host process, refers to the ongoing conversation between the local host and the remote host

Transport Layer

Define the protocol port number for data transmission, as well as flow control and error checking. Provide logical communication between application processes
Protocols are: TCP UDP (data packets enter the network transport layer once they leave the network card)
Commonly used: SPX, process, port (socket)

Network Layer

Perform logical address addressing to realize path selection between different networks.
Protocols are: ICMP IGMP IP (IPV4 IPV6)
Common: routers, multilayer switches, firewalls

Data Link Layer

Establish logical connection, perform hardware address addressing, error checking and other functions. (The protocol is defined by the underlying network)
Combining bits into bytes and then into frames, using MAC addresses to access the medium, errors are found but cannot be corrected.
Common: bridge, network card, layer 2 switch

Physical Layer

Establish, maintain, and disconnect physical connections. (The protocol is defined by the underlying network)
Common: network cable, hub, repeater, HUB, RJ-45 standard

The application layer needs to care about the logical details of the application, not the data transmission activity in the network. The application layer and the lower three layers deal with the real communication details. All the ideas and emphasis in the entire development of the Internet exist in a document format called RFC (Request For Comments). For each specific TCP/IP application, there are corresponding RFC documents.

TCP/IP protocol

TCP/IP definition

TCP/IP is the abbreviation of "transmission Control Protocol/Internet Protocol", the Chinese translation is called Transmission Control Protocol/Internet Protocol, TCP/IP (Transmission Control Protocol/Internet Protocol) is a network communication protocol, it regulates the network All communication equipment in the world, especially the data exchange format and transmission method between one host and another host.

TCP/IP is the basic protocol of the Internet, and it is also a standard method for computer data packaging and addressing. In data transmission, it can be visually understood as having two envelopes. TCP and IP are like envelopes. The information to be transmitted is divided into several segments. Each segment is stuffed into a TCP envelope, and the points are recorded on the envelope. The information of the segment number, then stuff the TCP envelope into the IP envelope and send it to the Internet. At the receiving end, a TCP software package collects the envelope, extracts the data, restores it in the order before sending, and checks it. If an error is found, TCP will request a retransmission. Therefore, TCP/IP can transmit data almost error-free in the Internet. For ordinary users, they do not need to understand the entire structure of the network protocol, but only need to understand the IP address format to communicate with all parts of the world.
Insert picture description here

Application layer

The application layer corresponds to the OSI application layer, presentation layer, and session layer. It enables applications to run directly on the transport layer and directly provide services to users. The main protocols included are File Transfer Protocol (FTP), Simple Mail Transfer Protocol (SMTP), Telnet Protocol, Domain Name Service (DNS), and Network News Transfer Protocol (Network News Transfer Protocol). News Transfer Protocol, NNTP) and Hyper Text Transfer Protocol (HTTP), etc.

Transport layer

The transport layer corresponds to the transport layer of the OSI model. Its main function is to divide the user information passed by the application layer into several datagrams and add headers to facilitate end-to-end communication. The included protocol includes basic byte connection-oriented application layer transmission TCP protocol, TCP provides reliable connection for data transmission between applications; connectionless user datagram UDP protocol, UDP transmission does not guarantee that the data will not reach the destination. It does not guarantee the order of datagrams, and does not provide a retransmission mechanism; it provides NVP protocol for voice transmission services.

Network layer

The network layer corresponds to the network layer of the OSI model. The protocol used in this layer is called the Internet Protocol, which provides addressing and routing functions across multiple networks, enabling IP data (with IP addresses) to be transmitted from a host on one network to a host on another network. The protocols included are Internet IP protocol; Internet Control Message Protocol ICMP; ARP protocol that converts IP addresses into physical network layer addresses; and RARP protocol that converts physical network addresses into IP addresses.

Network interface layer

In the TCP/IP four-layer architecture, the data link layer and the physical layer are combined into a network interface layer, which corresponds to the OSI data link layer and the physical layer. The TCP/IP five-layer architecture is separated. This layer is responsible for the management of the actual network media, defining how to use the actual network (such as Ethernet, Serial Line, etc.) to transmit data, and also includes the device drivers in the operating system and the corresponding network interface card in the computer.

Guess you like

Origin blog.csdn.net/Mr_Bobcp/article/details/106147252