Basic OSI Layer-7 model knowledge and common applications

Source: Internet
Author: User

OSI Layer-7 model basic knowledge and common application OSI Open Source Initiative (OSI for short, Open Source code Promotion Association, Open Source code organization) is a non-profit organization designed to promote the development of Open Source software. The full name of the OSI Reference Model (OSI/RM) is the Open System Interconnection Reference Model (OSI/RM ), it is a network system interconnection model proposed by ISO. It is the foundation of network technology and the basis for analyzing and judging various network technologies. It opens the secrets of the network, so that it can be justified and evidence-based. I. OSI reference model knowledge points Chart 1: OSI model basic knowledge speed view model divides network communication into seven layers. Layers 1 to 4 are considered as low layers, which are closely related to data movement. Layer 5 to Layer 7 are high-level and contain application-level data. Each layer is responsible for a specific task, and then transmits data to the next layer. It can be divided into the physical layer, data link layer, network layer, transmission layer, Session Layer, presentation layer, and application layer. Layer-3 Application Layer-provides services directly to applications, and applications can be changed. However, the layer-3 Presentation Layer of electronic message transmission-formatting data should be included to provide common interfaces for applications. This can include the Layer 2 Session Layer of the data encryption service-Establishing an end connection between two nodes. This service includes setting up connections in full or half duplex mode, although duplex mode 4th layer transport layer-conventional data delivery-connection oriented or connectionless mode can be processed in Layer 4. Including full or half duplex, traffic control, and error recovery services Layer 3 network layer-this layer establishes connections between two nodes through addressing, it includes routing and relay data through an interconnected network. Layer 3 data link layer-this layer splits data into frames and processes stream control. This layer specifies the topological structure and provides hardware addressing Layer 2 Physical Layer-transmission of electronic signals from original bit streams and transmission of hardware interface data from Layer 7 to the first layer. The receiver is the opposite. The typical devices of each layer are as follows: Application Layer ................... COMPUTER: applications, such as FTP, SMTP, and HTTP presentation layer ................... COMPUTER: encoding method, image codec, URL field Transfer Encoding Session Layer ................... COMPUTER: establishes SESSION, SESSION authentication, and resumable transmission layer ................... COMPUTER: process and port network layer ..................... Network: vro, firewall, and multi-layer switch data link layer ........... Network: Nic, bridge, switch physical layer ..................... Network: repeater, HUB, network cable, HUB 2. Proposal of OSI basic knowledge OSI/RM reference model the world's first network architecture proposed by IBM (74 years, SNA ), in the future, other companies have successively proposed their network architecture, such as Digital's DNA and the TCP/IP of the U. S. Anti-DDoS department. Multiple network architectures coexist, the result is that if the structure of IBM is used, only IBM products can be used, and only networks with the same structure can be interconnected. In order to promote the development of computer networks, ISO established a committee in 1977. Based on the existing network, it proposed a network architecture not based on specific models, operating systems or companies, the OSI model is designed to become an open network model that can be implemented by all vendors, to overcome the difficulties and inefficiency caused by the use of many private network models. OSI was completed with the participation of a highly respected international standards group, which is ISO (International Standardization Organization ). OSI stands for Open System Interconnection, which is the reference model for Open System Interconnection. Prior to the emergence of OSI, there were numerous architectures in the computer Network, with IBM's SNA (System Network Architecture) and DEC's DNA (Digital Network Architecture) the digital network architecture is the most famous. In order to solve the Interconnection problem between networks of different architectures, ISO (Be careful not to mix with OSI) developed an Open System Interconnection Reference Model (Open System Interconnection Reference Model) in 1981, OSI/RM ). This model divides Network communication into seven layers, which are Physical Layer (Physical Layer), Data Link Layer (Data Link Layer), and Network Layer (Network Layer ), transport Layer, Session Layer, Presentation Layer, and Application Layer ). The layer 1 to Layer 3 belongs to the lower layer of the OSI reference model and is responsible for creating network communication links. The Layer 4 to Layer 7 is the high-level layer of the OSI reference model, which is responsible for end-to-end data communication. Each layer provides certain functions, each layer provides services for its upper layer, and all layers support each other, while network communication can be top-down (on the sending end) or two-way implementation from the bottom up (at the receiving end. Of course, not every message needs to pass through all Layer 7 of OSI, and some even only need a layer corresponding to both parties. The transfer between physical interfaces and the connection between the repeater and the repeater only needs to be performed in the physical layer. The connection between the router and the router only needs to pass through the Layer 3 below the network layer. In general, the communication between the two parties is at the peer level and cannot be at the asymmetric level. The method used in OSI Standard Setup is to divide the entire large and complex problem into several small problems that are easy to handle. This is a hierarchical architecture approach. Three levels of abstraction are used in OSI, including architecture, service definition, and Protocol Specification Description. OSI hierarchy principle each node in the network has the same hierarchy, different nodes have the same hierarchy, the same function, the same node, the adjacent layers communicate with each layer through interfaces, each layer can use the services provided by the lower layer, the upstream layer provides services at different nodes through the same layer through the Protocol to achieve peer-to-peer inter-layer communication OSI/RM layered structure the essence of peer-layer communication during inter-layer communication: virtual Communication between peer-layer entities; the lower layer provides services to the upper layer; the actual communication is completed at the bottom layer, and the sender data is gradually transferred to the lower layer, and the receiver data is gradually transferred to the upper layer from the lowest layer. in the pdu si reference model, information units exchanged between peer-to-peer protocols are collectively referred to as Protocol Data units (PDU, Protocol Data Unit ). The PDU at the transport layer and the following layers also have their own specific names: Transport Layer-Data Segment (Segment) network layer-group (Packet) data link layer-data Frame) physical Layer-Bit 3. Layer 7 structure of OSI Layer 1: Physical Layer (PhysicalLayer) specifies the mechanical, electrical, functional, and process characteristics of communication equipment, it is used to establish, maintain, and remove physical link connections. Specifically, the mechanical characteristics specify the specifications, sizes, number of pins, and arrangement of connectors required for network connection; the electrical characteristic specifies the signal level, impedance matching, and transmission speed limit on the line when the bit stream is transmitted on the physical connection. The function characteristic refers to assigning the exact signal meaning to each signal first, that is, the function of each line between DTE and DCE is defined. The process feature defines a set of Operation Procedures for bit stream transmission using signal lines, it refers to the action series of the DTE and DCE on each circuit when the physical connection is established, maintained, and information is exchanged. At this layer, the unit of data is bit ). Representative of typical specifications defined by the physical layer include: EIA/TIA RS-232, EIA/TIA RS-449, V.35, RJ-45, etc. The main function of the physical layer: provides a data transmission path for the data device. The data path can be a physical media or a connection of multiple physical media. A complete data transfer, including activating a physical connection, transferring data, and terminating a physical connection. activation means that no matter how many physical media are involved, the two data terminal devices in the communication must be connected to form a channel. transmit data. the physical layer must form entities suitable for data transmission and serve data transmission. first, ensure that the data can pass through the data correctly, and second, provide sufficient bandwidth (bandwidth refers to the number of BITs that can pass each second ), to reduce channel congestion. the data transmission method can meet the requirements of point-to-point, point-to-point, serial or parallel, half-duplex or full-duplex, synchronous or asynchronous transmission. completes some management of the physical layer. main devices of the physical layer: Relay and hub. Product representatives: TP-LINK TL-HP8MU hub Layer 2: data link layer (DataLinkLayer) in the physical layer to provide the bit stream service, the establishment of data links between adjacent nodes, through error control to provide data Frame (Frame) in the channel error-free transmission, and each circuit on the action series. The data link layer provides reliable transmission on unreliable physical media. The role of this layer includes physical address addressing, data frame formation, traffic control, data error detection, and re-transmission. At this layer, the unit of data is frame ). Data link layer protocols include SDLC, HDLC, PPP, STP, and frame relay. The main function of the link layer: the link layer provides the data transmission service for the network layer, which relies on the functions of this layer. The link layer should have the following functions: Establish, remove, and separate link connections. Frame demarcation and frame synchronization. The data transmission unit at the link layer is a frame. The protocol is different, and the frame length and interface are also different. However, frames must be bounded in any case. Sequential Control refers to the control of the sending and receiving sequence of frames. Error Detection and recovery. There are also link identification and traffic control. error Detection uses square matrix code verification and cyclic code verification to detect the error codes of data on the channel, while Frame loss uses serial number detection. recovery of various errors often relies on feedback and resend technology. Data Link layer Main Equipment: layer 2 switch, net bridge product representative: D-Link DES-1024D layer 3: Network layer) the two computers that communicate in the computer network may go through many data links or through many communication subnets. The task at the network layer is to select an appropriate inter-network route and exchange node to ensure timely data transmission. The Network Layer encapsulates the frames provided by the data link layer into a data packet. The packet contains a network packet header, which contains the logical address information-the network address of the source site and the destination site. If you are talking about an IP address, you are dealing with layer-7 problems. This is a "packet" problem, not a "frame" of layer-7 ". IP addresses are part of Layer 2 issues. In addition, there are some routing protocols and IP Address Resolution protocols (ARP ). Everything about routing is handled at Layer 3rd. Address Resolution and routing are the important purposes of Layer 3. The network layer can also implement congestion control, Internet interconnection, and other functions. At this layer, the unit of data is called packet ). Network Layer Protocols include IP, IPX, RIP, and OSPF. Main functions of the network layer: to establish a network connection and provide services for the upper layer, the network layer should have the following main functions: Route Selection and relay activation, and terminate the network connection to reuse multiple network connections on a data link, take multiple time-sharing technology error detection and recovery sorting, traffic control service selection network management network layer standard introduction network layer Main Equipment: router product representatives: TP-LINK TL-R4148 layer: the data unit at the Transport layer (Transport layer), also known as packets, that processes information ). However, when you talk about specific protocols such as TCP, there is a special name. TCP data units are called segments, while UDP data units are called "datagram Rams )". This layer is responsible for obtaining all information. Therefore, it must track data unit fragments, unordered data packets, and other possible risks during transmission. Layer 3 provides an end-to-end (end user to end user) transparent and reliable data transmission service for the upper layer. Transparent transmission means that the transmission layer shields the details of the communication transmission system from the upper layer during the communication process. The Transport Layer Protocol includes TCP, UDP, and SPX. The transport layer is the first end-to-end Layer for data communication between two computers over the network. When the network layer service quality does not meet the requirements, it improves the Service to meet the requirements of the senior level. When the network layer service quality is good, it only uses a small amount of work. The transport layer can also be reused, that is, multiple logical connections can be created on a network connection. The transport layer is also called the transport layer. the transport layer only exists in the end-to-end open system. It is a layer between the low-Layer 3 Communication Subnet system and the high-Layer 3, but a very important layer. it is the last layer from the source to the target to control data transmission. there is a fact that the performance of various communication subnets in the world is very different. for example, Communication subnets such as the telephone exchange network, group exchange network, Public Data Exchange Network, and LAN can be interconnected, but the throughput, transmission rate, and data delay communication fees are different. for the session layer, a constant performance interface is required. the Transport Layer undertakes this function. it uses the shunting/confluence, multiplexing/multiplexing technology to adjust the differences between the above communication subnets, so that the Session Layer does not feel it. in addition, the transport layer also provides error recovery, traffic control, and other functions to shield the Session Layer from the details and differences of the Communication Subnet in these aspects. the Data Object facing the transport layer is no longer the network address and host address, but the interface port of the Session Layer. the final purpose of the above functions is to provide reliable and error-free data transmission for sessions. services at the transport layer generally go through the transmission connection establishment phase, data transmission phase, and transmission connection release phase. A complete service process is completed, and the data transmission phase is divided into two types: general data transmission and accelerated data transmission. The transport layer service is divided into five types. basically, it can meet the different requirements of transmission quality, transmission speed, and transmission cost. product representative: NETGEAR GS748TS layer 5: Session layer can also be called the meeting layer or conversation layer. In the Session layer and above, the data transmission unit is no longer named, it is collectively referred to as a message. The Session Layer does not participate in specific transmission. It provides a mechanism to establish and maintain communications between applications, including access authentication and session management. For example, the Session Layer completes the authentication of user logon on the server. The Session Layer provides services that allow applications to establish and maintain sessions and synchronize sessions. The Session Layer uses the verification point to resume communication from the verification point when the communication fails. This capability is extremely important for transferring large files. The Session Layer, presentation layer, and application layer constitute the three high layers of the open system. They provide distributed processing, conversation management, information representation, and recovery of final Errors for application processes. the Session Layer is also responsible for the application process service requirements, but the transport layer cannot complete that part of the work, the transport layer function gap to make up. the main functions are dialog management, data stream synchronization, and re-synchronization. To complete these functions, a large number of service unit functions need to be combined. Dozens of functional units have been developed. The main functions of the Session Layer are described as follows. connections are established between session entities. To establish a session connection for two peer-to-peer session service users, you should map the session address to the Transport Address and select the required transport service quality parameters (QOS) session parameters are negotiated to identify the limited transparent User Data Transmission Phase transmitted by each session connection. This phase implements an organized and synchronized data transmission between two session users. the user data unit is SSDU, and the protocol data unit is SPDU. the data transfer process between session users is to convert SSDU into SPDU. connection release connection release releases Session connections through "ordered release", "obsolete", and "limited transparent user data transfer" and other functional units. the Session Layer standard defines 12 functional units in order to enable functional negotiation during the session connection establishment phase and to facilitate reference and reference of other international standards. each system can select other functional units to form a reasonable session service subset based on its own situation and needs. the main criteria for the Session Layer are "DIS8236: Session Service Definition" and "DIS8237: Session Protocol Specification ". layer 6: presentation layer (Presentatio N layer) This layer mainly solves the syntax expression problem of user information. It converts the data to be exchanged from an abstract syntax suitable for a user to a transfer syntax suitable for internal use within the OSI system. It provides formatted data representation and Conversion Services. The presentation layer is responsible for data compression, decompression, encryption, and decryption. The display of the sample image format is supported by the Protocol in the presentation layer. Layer 7: the Application layer provides interfaces for operating systems or network applications to access network services. Application layer protocols include Telnet, FTP, HTTP, and SNMP. Through the OSI Layer, information can be transmitted from a computer's software application to another application. For example, if an application on computer A sends information to an application on computer B, the application on computer A needs to first send the information to its application layer (Layer 7 ), this layer then sends the information to the presentation layer (layer 6), which transfers the data to the Session Layer (layer 5) until the physical layer (Layer 1 ). At the physical layer, data is stored in the physical network medium and sent to computer B. The physical layer of computer B receives data from physical media and sends the information to the data link layer (Layer 2). The data link layer then forwards the information to the network layer until the information reaches the application layer of computer B. Finally, the application layer of computer B transmits information to the application receiver to complete the communication process. The following figure shows the process. Layer 7 of OSI uses various control information to communicate with the corresponding layers of other computer systems. These control information contains special requests and descriptions that are exchanged between the corresponding OSI layers. The header and tail of each layer of data are two basic forms of carrying control information. For the data transmitted from the previous layer, the control information appended to the previous layer is called the header, and the control information appended to the previous layer is called the tail. However, adding protocol headers and Protocol tails to data from the previous layer is not necessary for an OSI layer. When data is transmitted between layers, each layer can add headers and tails to the data, and the data already contains the headers and tails added to the previous layer. The protocol header contains the communication information between the layer and the layer. Headers, tails, and data are associated. They depend on the protocol layer of the analysis information unit. For example, the transport layer header contains information that can only be seen by the transport layer. Other layers under the transport layer only transmit this header as part of the data. For the network layer, an information unit consists of the header and data of the third layer. For the data link layer, the layer-3 header and data are considered as data. In other words, in a given OSI layer, the data part of an information unit includes the header, tail, and data of all upper layers. This is called encapsulation. For example, if computer A wants to send data from an application to computer B, the data is first transmitted to the application layer. The application layer of computer A communicates with the application layer of computer B by adding A protocol header to the data. The information unit consists of the protocol header, data, and Protocol tail. It is sent to the presentation layer and then added as the protocol header of the control information understood by the presentation layer of computer B. The size of information units increases with the addition of each layer of protocol header and Protocol tail. These protocol headers and Protocol tails contain the control information to be used by the corresponding layer of computer B. On the physical layer, the entire Information Unit is transmitted through network media. The physical layer in computer B receives information units and sends them to the data link layer. Then, the data link layer in computer B reads the control information in the protocol header added to the data link layer of computer; remove the protocol header and end, and the rest is sent to the network layer. Each layer performs the same action: Read and remove the protocol header and end from the corresponding layer, and then send the remaining information to the first layer. After these actions are performed on the application layer, the data is transmitted to the application program in computer B, which is exactly the same as that sent by the application program in computer. The communication between one OSI Layer and the other layer is completed using the services provided by the second layer. The services provided by the adjacent layer help one OSI layer to communicate with the corresponding layer of another computer system. A specific layer of an OSI model is usually associated with the other three OSI layers: directly adjacent to the upper and lower layers, as well as the corresponding layers of the target networked computer system. For example, the data link layer of computer A should communicate with its network layer, physical layer, and data link layer of computer B. Iv. Advantages of OSI layering 1) it is easy for people to discuss and learn the specification details of protocols. (2) The standard interface between layers facilitates modular engineering. (3) creating a better interconnection environment. (4) Reduced Complexity, made the program easier to modify, and made product development faster. (5) Each layer makes it easier to remember the functions of each layer by taking advantage of the adjacent lower-layer services. OSI is a well-defined set of protocol specifications and has many optional parts for similar tasks. It defines the hierarchies of an open system, the relationships between hierarchies, and the possible tasks included in each layer. It is a framework to coordinate and organize the services provided by each layer. The OSI reference model does not provide an implementation method, but describes some concepts used to coordinate the establishment of inter-process communication standards. That is to say, the OSI reference model is not a standard, but a conceptual framework used in the standard. 5. Comparison between the OSI model and the TCP/IP model is actually a concentrated version of the OSI model, which has only four levels: 1. application Layer 2. transport Layer 3. internet Layer 4. compared with OSI functions, the network interface layer: the application layer corresponds to the OSI Application layer. The session layer transport layer corresponds to the OSI transport layer. The Internet layer corresponds to the OSI network layer. The network interface layer corresponds to the OSI data link layer and the physical layer.

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: 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.