Data units in the osi model. What is the seven-layer OSI model - why is it needed and how does it work?

Just started working as a network administrator? Don't want to get confused? Our article will be useful to you. Have you heard a time-tested administrator talk about network problems and mention some levels? Have you ever been asked at work what layers are secure and work if you are using an old firewall? To understand the basics information security, you need to understand the principle of the hierarchy of the OSI model. Let's try to see the capabilities of this model.

A self-respecting system administrator should be well versed in network terms

Translated from English - basic reference model of interaction open systems. More precisely, the network model of the OSI/ISO network protocol stack. Introduced in 1984 as a conceptual framework that separated the process of sending data to world wide web in seven easy steps. It is not the most popular, since the development of the OSI specification has been delayed. The TCP/IP protocol stack is more advantageous and is considered the main model used. However, you have a huge chance to encounter the OSI model as a system administrator or in the IT field.

Many specifications and technologies have been created for network devices. It's easy to get confused in such diversity. It is the open systems interaction model that helps network devices using each other to understand each other. various methods communication. Note that OSI is most useful for software and hardware involved in the design of compatible products.

Ask, what benefit does this have for you? Knowledge of the multi-level model will give you the opportunity to freely communicate with employees of IT companies; discussing network problems will no longer be oppressive boredom. And when you learn to understand at what stage the failure occurred, you can easily find the reasons and significantly reduce the range of your work.

OSI levels

The model contains seven simplified steps:

  • Physical.
  • Duct.
  • Network.
  • Transport.
  • Sessional.
  • Executive.
  • Applied.

Why does breaking it down into steps make life easier? Each level corresponds to a specific stage of sending a network message. All steps are sequential, which means that the functions are performed independently, there is no need for information about the work at the previous level. The only necessary components are how the data from the previous step is received, and how the information is sent to the subsequent step.

Let's move on to a direct acquaintance with the levels.

Physical layer

The main task of the first stage is sending bits through physical communication channels. Physical communication channels are devices created for transmitting and receiving information signals. For example, optical fiber coaxial cable or twisted pair. Transfer can also take place via wireless communication. The first stage is characterized by the data transmission medium: protection from interference, bandwidth, characteristic impedance. The qualities of the electrical final signals (type of encoding, voltage levels and signal transmission speed) are also set and brought to standard types connectors, contact connections are assigned.

The functions of the physical stage are performed on absolutely every device connected to the network. For example, a network adapter implements these functions on the computer side. You may have already encountered the first step protocols: RS-232, DSL and 10Base-T, which define the physical characteristics of the communication channel.

Data Link Layer

At the second stage, the abstract address of the device is associated with the physical device, and the availability of the transmission medium is checked. Bits are formed into sets - frames. Main task link layer- identifying and correcting errors. For correct transmission, specialized bit sequences are inserted before and after the frame and a calculated checksum is added. When the frame reaches the destination, the checksum of the already arrived data is calculated again if it matches checksum in the frame, the frame is recognized as correct. Otherwise, an error appears that can be corrected by retransmitting information.

The channel stage makes it possible to transmit information thanks to a special connection structure. In particular, buses, bridges, and switches operate through link layer protocols. Step two specifications include: Ethernet, Token Ring and PPP. The functions of the channel stage in a computer are performed by network adapters and drivers for them.

Network layer

In standard situations, the functions of the channel stage are not enough for high-quality information transfer. Second step specifications can only transfer data between nodes with the same topology, for example, a tree. There is a need for a third stage. It is necessary to form a unified transport system with a branched structure for several networks that have an arbitrary structure and differ in the method of data transfer.

To explain it another way, the third step processes the Internet protocol and performs the function of a router: finding the best path for the information. Router - a device that collects data about the structure of interconnections network connections and transmitting packets to the destination network (transit transmissions - hops). If you encounter an error in the IP address, then it is a problem originating at the network level. Stage three protocols are broken down into networking, routing or address resolution protocols: ICMP, IPSec, ARP and BGP.

Transport layer

In order for the data to reach applications and the upper layers of the stack, a fourth stage is required. It provides the required degree of reliability of information transmission. There are five classes of transport stage services. Their difference lies in the urgency, feasibility of restoring interrupted communication, and the ability to detect and correct transmission errors. For example, packet loss or duplication.

How to choose a transport stage service class? When the quality of communication channels is high, a lightweight service is an adequate choice. If communication channels do not work securely at the very beginning, it is advisable to resort to a developed service that will provide maximum opportunities for finding and solving problems (control of data delivery, delivery timeouts). Stage 4 specifications: TCP and UDP of the TCP/IP stack, SPX of the Novell stack.

Association first four levels is called the transport subsystem. It fully provides the selected level of quality.

Session layer

The fifth stage helps in regulating dialogues. It is impossible for interlocutors to interrupt each other or speak synchronously. The session layer remembers the active party at a particular moment and synchronizes information, coordinating and maintaining connections between devices. Its functions allow you to return to a checkpoint during a long transfer without having to start all over again. Also at the fifth stage, you can terminate the connection when the exchange of information is completed. Session layer specifications: NetBIOS.

Executive level

The sixth stage is involved in the transformation of data into a universal recognizable format without changing the content. Since in different devices various formats are utilized, information processed at the representational level makes it possible for systems to understand each other, overcoming syntactic and coding differences. In addition, at the sixth stage, it becomes possible to encrypt and decrypt data, which ensures secrecy. Examples of protocols: ASCII and MIDI, SSL.

Application layer

The seventh stage on our list and the first if the program sends data over the network. Consists of sets of specifications through which the user, Web pages. For example, when sending messages by mail, it is at the application level that a convenient protocol is selected. The composition of the seventh stage specifications is very diverse. For example, SMTP and HTTP, FTP, TFTP or SMB.

You may have heard somewhere about the eighth level of the ISO model. Officially, it does not exist, but a comic eighth stage has appeared among IT workers. This is all due to the fact that problems can arise due to the fault of the user, and as you know, a person is at the pinnacle of evolution, so the eighth level appeared.

Having considered the OSI model, you were able to understand the complex structure of the network and now understand the essence of your work. Things get pretty simple when you break the process down!

OSI has seven layers. In Fig. Figure 1.5 shows a model of interaction between two devices: source node(source) and destination node(destination). The set of rules by which data is exchanged between software and hardware located at the same level is called a protocol. A set of protocols is called a protocol stack and is defined by a specific standard. Interaction between levels is determined by standard interfaces.


Rice. 1.5.

The interaction of the corresponding levels is virtual, except physical level, where data is exchanged via cables connecting computers. In Fig. 1.5 also provides examples of protocols that control the interaction of nodes at various levels of the OSI model. Interaction between levels within a node occurs through inter-level interface, and each lower level provides services to the higher one.

Virtual exchange between the corresponding levels of nodes A and B (Fig. 1.6) occurs with certain units of information. On the top three levels it is messages or data, at the transport level – segments, at the network level – Packets, at the link level – Frame) and on the physical – a sequence of bits.

For each network technology There are their own protocols and their own technical means, some of which have the symbols shown in Fig. 1.5. These designations were introduced by Cisco and have become generally accepted. Among the technical means of the physical layer, it should be noted cables, connectors, signal repeaters, multiport repeaters or concentrators (hub), media converters (transceiver), for example, converters of electrical signals into optical signals and vice versa. At the link level this is bridges, switches. At the network level - routers. Network cards or adapters (Network Interface Card - NIC) operate both at the data link and at the physical level, which is due to network technology And data transmission medium.


Rice. 1.6.

When transmitting data from a source to a destination node, the transmitted data prepared at the application level sequentially passes from the highest, Application level 7 of the information source node to the lowest - Physical level 1, then is transmitted through the physical medium to the destination node, where it sequentially passes from the lower level 1 to level 7.

The top one Application Layer 7 operates with the most common unit of data – a message. At this level management is implemented shared access to the network, data flow, network services such as FTP, TFTP, HTTP, SMTP, SNMP etc.

Presentation Layer 6 changes the form of data presentation. For example, data transferred from layer 7 is converted to the generally accepted ASCII format. When receiving data, the reverse process occurs. Layer 6 also encrypts and compresses data.

Session Layer 5 establishes a communication session between two end nodes (computers), determines which computer is a transmitter and which is a receiver, and sets the transmission time for the transmitting side.

Transport Layer 4 divides a large message from the information source node into parts, while adding a header and generating segments of a certain volume, and short messages can be combined into one segment. At the destination node the reverse process occurs. The segment header specifies port numbers source and destination, which direct upper application layer services to process a given segment. Besides, transport layer ensures reliable delivery of packages. If losses and errors are detected at this level, a retransmission request is generated using the protocol TCP. When there is no need to verify the correctness of the delivered message, the simpler and faster User Datagram Protocol is used. UDP).

Network Layer 3 addresses a message by specifying the unit of data being transmitted (package) logical network addresses destination node and source node ( IP addresses), defines route by which it will be sent data package, translates logical network addresses into physical ones, and on the receiving side - physical addresses to logical. Network logical addresses belong to users.

Data Link 2 forms from packages personnel data (frames). At this level they are set physical addresses sender and receiver devices. For example, physical address devices can be registered in the ROM of the computer’s network card. At the same level, it is added to the transmitted data checksum, determined using the algorithm cyclic code. On the receiving side checksum identify and, if possible, correct errors.

Physical layer (Physical) 1 transmits a stream of bits over the appropriate physical medium (electrical or optical cable, radio channel) through the appropriate interface. At this level, data is encoded and the transmitted bits of information are synchronized.

The protocols of the three upper layers are network-independent, the three lower layers are network-dependent. Communication between the upper three and lower three layers occurs at the transport layer.

An important process in data transfer is encapsulation(encapsulation) of data. The transmitted message generated by the application passes through the three upper network-independent layers and arrives at transport layer, where it is divided into parts and each part is encapsulated (placed) in a data segment (Fig. 1.7). The segment header contains the number of the application layer protocol with which the message was prepared, and the number of the protocol that will process this segment.


Rice. 1.7.

At the network level, a segment is encapsulated in plastic bag data, header ( header) which contains, among other things, the network (logical) addresses of the information sender (source) – Source Address ( S.A.) and recipient (destination) – Destination Address ( D.A.). In this course, these are IP addresses.

At the data link layer, the packet is encapsulated in frame or frame data whose header contains physical addresses transmitter and receiver nodes, as well as other information. In addition, at this level it is added trailer(trailer) of a frame containing information necessary to verify the correctness of the received information. Thus, the data is framed with headers containing service information, i.e. encapsulation data.

The name of information units at each level, their size and other encapsulation parameters are set according to the Protocol Data Unit - PDU). So, at the top three levels this is message (Data), at Transport Layer 4 – segment, at Network layer 3 – Packet, at Link Layer 2 – frame, at Physical Level 1 – bit sequence.

In addition to the seven-layer OSI model, the four-layer TCP / IP model is used in practice (Fig. 1.8).


Rice. 1.8.

Application layer The TCP/IP model has the same name as the OSI model, but its functions are much broader, since it covers the three upper network-independent layers (application, presentation and session). Transport layer Both models are the same in name and function. The network layer of the OSI model corresponds to the internetwork ( Internet) layer of the TCP/IP model, and the two lower layers (link and physical) are represented by the unified network access layer ( Network Access).


Rice. 1.9.

Thus, Transport layer, which ensures reliable data transmission, operates only on end nodes, which reduces latency message transmission throughout the network from one end node to another. In the example given (Fig. 1.9), the IP protocol operates on all network nodes, and the TCP / IP protocol stack operates only on end nodes.

Brief summary

  1. A telecommunications network is formed by a set of subscribers and communication nodes connected by communication lines (channels).
  2. Distinguish networks: circuit switched, when telecommunication nodes perform the functions of switches, and with packet (message) switching, when telecommunication nodes perform the functions of routers.
  3. To create a route in a branched network, you must specify the source addresses and message recipient. There are physical and logical addresses.
  4. Data networks With packet switching are divided into local and global.
  5. IP technology networks are datagram when there is no preliminary connection of end nodes and there is no acknowledgment of message receipt.
  6. High reliability ensures

To make it easier to understand the operation of all the network devices listed in the article Network Devices regarding the layers of the OSI Network Reference Model, I have made schematic drawings with small comments.

First, let's remember the layers of the OSI reference network model and data encapsulation.

See how data is transferred between two connected computers. At the same time, I will highlight the work of the network card on computers, because It is precisely this that is a network device, but a computer is not. (All pictures are clickable - to enlarge the picture, click on it.)


An application on PC1 sends data to another application on PC2. Starting from the top layer (application layer), data is sent to the network card to the data link layer. On it network card converts frames into bits and sends them to a physical medium (for example, twisted pair cable). A signal arrives on the other side of the cable, and the PC2 computer's network card receives these signals, recognizing them into bits and forming frames from them. The data (contained in the frames) is decapsulated to the top layer, and when it reaches the application layer, the corresponding program on PC2 receives it.

Repeater. Hub.

A repeater and a hub operate at the same level, so they are depicted the same in terms of the OSI network model. For the convenience of representing network devices, we will display them between our computers.


Repeater and concentrator of the first (physical) level device. They receive the signal, recognize it, and forward the signal to all active ports.

Network bridge. Switch.

The network bridge and the switch also operate at the same level (channel) and are depicted in the same way.


Both devices are already at the second level, so in addition to recognizing the signal (like hubs at the first level), they decapsulate it (the signal) into frames. At the second level, the checksum of the trailer (trailer) of the frame is compared. Then the recipient's MAC address is learned from the frame header and its presence in the switched table is checked. If the address is present, then the frame is encapsulated back into bits and sent (as a signal) to the corresponding port. If the address is not found, the process of searching for this address in connected networks occurs.

Router.


As you can see, a router (or router) is a third-level device. Here's roughly how the router functions: A signal arrives at the port, and the router recognizes it. The recognized signal (bits) form frames (frames). The checksum in the trailer and the recipient's MAC address are checked. If all checks are successful, the frames form a packet. At the third level, the router examines the packet header. It contains the IP address of the destination (recipient). Based on the IP address and its own routing table, the router selects the best path for packets to take to the recipient. Having selected a path, the router encapsulates the packet into frames and then into bits and sends them as signals to the appropriate port (selected in the routing table).

Conclusion

In conclusion, I combined all the devices in one picture.


Now you have enough knowledge to determine which devices work and how they work. If you have any questions, ask them to me and in the near future either I or other users will certainly help you.

To provide a unified representation of data in networks with heterogeneous devices and software, the international organization for standards ISO (International Standardization Organization) has developed a basic model for open systems communication OSI (Open System Interconnection). This model describes the rules and procedures for transmitting data in various network environments when organizing a communication session. The main elements of the model are layers, application processes and physical connections. In Fig. Figure 1.10 shows the structure of the basic model.

Each layer of the OSI model performs a specific task during the transmission of data over the network. The basic model is the basis for the development of network protocols. OSI divides network communication functions into seven layers, each of which serves different parts of the open systems interconnection process.

The OSI model describes only system communications, not end-user applications. Applications implement their own communication protocols by accessing system facilities.

Rice. 1.10. OSI model

If an application can take on the functions of some of the upper layers of the OSI model, then to exchange data it accesses directly the system tools that perform the functions of the remaining lower layers of the OSI model.

Interaction of OSI Model Layers

The OSI model can be divided into two various models, as shown in Fig. 1.11:

A horizontal protocol-based model that provides a mechanism for interaction between programs and processes on different machines;

A vertical model based on services provided by adjacent layers to each other on the same machine.

Each layer of the sending computer interacts with the same layer of the receiving computer as if it were directly connected. Such a connection is called a logical or virtual connection. In reality, interaction occurs between adjacent levels of one computer.

So, the information on the sending computer must pass through all levels. It is then transmitted through the physical medium to the receiving computer and again passes through all the layers until it reaches the same level from which it was sent to the sending computer.

In the horizontal model, two programs require a common protocol to exchange data. In a vertical model, adjacent layers exchange data using interfaces application programs API (Application Programming Interface).

Rice. 1.11. Diagram of computer interaction in the OSI Basic Reference Model

Before being sent to the network, the data is divided into packets. A packet is a unit of information transmitted between network stations.

When sending data, the packet passes sequentially through all layers software. At each level, control information of this level (header) is added to the packet, which is necessary for successful data transmission over the network, as shown in Fig. 1.12, where Zag is the header of the packet, Con is the end of the packet.

At the receiving end, the packet passes through all layers in reverse order. At each layer, the protocol at that layer reads the packet information, then removes the information added to the packet at that layer by the sending party, and passes the packet to the next layer. When the packet reaches the Application Layer, all control information will be removed from the packet and the data will return to its original form.

Rice. 1.12. Formation of a package of each level of the seven-level model

Each level of the model performs its own function. The higher the level, the more complex the problem it solves.

It is convenient to think of the individual layers of the OSI model as groups of programs designed to perform specific functions. One layer, for example, is responsible for providing data conversion from ASCII to EBCDIC and contains the programs needed to perform this task.

Each layer provides a service to the layer above it, in turn requesting service from the layer below it. The upper layers request service in almost the same way: as a rule, this is a requirement to route some data from one network to another. The practical implementation of data addressing principles is assigned to the lower levels. In Fig. 1.13 given brief description functions at all levels.

Rice. 1.13. Functions of the OSI Model Layers

The model under consideration determines the interaction of open systems different manufacturers on the same network. Therefore, she performs coordinating actions for them on:

Interaction of application processes;

Data presentation forms;

Uniform data storage;

Network resource management;

Data security and information protection;

Diagnostics of programs and hardware.

Application layer

The application layer provides application processes with a means of access to the interaction area, is the top (seventh) level and is directly adjacent to the application processes.

In reality, the application layer is a set of various protocols with which network users access shared resources, such as files, printers or hypertext Web pages, and also organize their joint work, for example using the protocol email. Special application service elements provide service for specific application programs, such as file transfer programs and terminal emulation programs. If, for example, a program needs to transfer files, then the FTAM (File Transfer, Access, and Management) file transfer, access and management protocol will be used. In the OSI model, an application program that needs to perform a specific task (for example, updating a database on a computer) sends specific data in the form of a Datagram to the application layer. One of the main tasks of this layer is to determine how the application request should be processed, in other words, what form the request should take.

The unit of data that the application layer operates on is usually called a message.

The application layer performs the following functions:

1. Performing various types of work.

File transfer;

Job management;

System management, etc.;

2. Identification of users by their passwords, addresses, electronic signatures;

3. Determination of functioning subscribers and the possibility of access to new application processes;

4. Determining the sufficiency of available resources;

5. Organization of requests for connection with other application processes;

6. Transfer of applications to the representative level for the necessary methods of describing information;

7. Selection of procedures for the planned dialogue of processes;

8. Management of data exchanged between application processes and synchronization of interaction between application processes;

9. Determination of quality of service (delivery time of data blocks, acceptable error rate);

10. Agreement to correct errors and determine the reliability of data;

11. Coordination of restrictions imposed on syntax (character sets, data structure).

These functions define the types of services that the application layer provides to application processes. In addition, the application layer transfers to application processes the services provided by the physical, link, network, transport, session and presentation layers.

At the application level, it is necessary to provide users with already processed information. System and user software can handle this.

The application layer is responsible for application access to the network. The tasks of this level are file transfer, exchange by mail and network management.

The most common protocols in the top three layers include:

FTP (File Transfer Protocol) file transfer protocol;

TFTP (Trivial File Transfer Protocol) is the simplest file transfer protocol;

X.400 email;

Telnet work with a remote terminal;

SMTP (Simple Mail Transfer Protocol) is a simple mail exchange protocol;

CMIP (Common Management Information Protocol) common information management protocol;

SLIP (Serial Line IP) IP for serial lines. Protocol for serial character-by-character data transmission;

SNMP (Simple Network Management Protocol) is a simple network management protocol;

FTAM (File Transfer, Access, and Management) protocol for transferring, accessing and managing files.

Presentation layer

The functions of this level are the presentation of data transferred between application processes in the required form.

This layer ensures that information conveyed by the application layer will be understood by the application layer in another system. If necessary, the presentation layer, at the time of information transmission, converts data formats into some general presentation format, and at the time of reception, accordingly, performs the reverse conversion. In this way, application layers can overcome, for example, syntactic differences in data representation. This situation can arise on a LAN with computers of different types (IBM PC and Macintosh) that need to exchange data. Thus, in database fields, information must be presented in the form of letters and numbers, and often in the form of a graphic image. This data needs to be processed, for example, as floating point numbers.

The basis for the general presentation of data is the ASN.1 system, uniform for all levels of the model. This system serves to describe the file structure and also solves the problem of data encryption. At this level, encryption and decryption of data can be performed, thanks to which the secrecy of data exchange is ensured for all application services at once. An example of such a protocol is the Secure Socket Layer (SSL) protocol, which provides secure messaging for application layer protocols in the TCP/IP stack. This level provides data conversion (encoding, compression, etc.) of the application layer into a stream of information for the transport layer.

The representative level performs the following main functions:

1. Generating requests to establish interaction sessions between application processes.

2. Coordination of data presentation between application processes.

3. Implementation of data presentation forms.

4. Presentation of graphic material (drawings, pictures, diagrams).

5. Classification of data.

6. Transmission of requests to terminate sessions.

Presentation layer protocols are typically integral part protocols of the three upper levels of the model.

Session layer

The session layer is a layer that defines the procedure for conducting sessions between users or application processes.

The session layer provides conversation management to record which party is currently active and also provides synchronization facilities. The latter allow checkpoints to be inserted into long transfers, so that in the event of a failure, you can go back to the last checkpoint, rather than starting all over again. In practice, few applications use the session layer, and it is rarely implemented.

The session layer controls the transfer of information between application processes, coordinates the reception, transmission and delivery of one communication session. In addition, the session layer additionally contains the functions of password management, dialogue management, synchronization, and cancellation of communication in a transmission session after a failure due to errors in lower layers. The functions of this level are to coordinate communication between two application programs running on different workstations. This occurs in the form of a well-structured dialogue. These functions include creating a session, managing the sending and receiving of message packets during a session, and terminating a session.

At the session level, it is determined what the transfer will be between two application processes:

Half-duplex (processes will transmit and receive data in turn);

Duplex (processes will transmit data and receive it at the same time).

In half-duplex mode, the session layer issues a data token to the process that initiates the transfer. When it is time for the second process to respond, the data token is passed to it. The session layer allows transmission only to the party that has the data token.

The session layer provides the following functions:

1. Establishment and termination at the session level of a connection between interacting systems.

2. Performing normal and urgent data exchange between application processes.

3. Management of interaction between application processes.

4. Synchronization of session connections.

5. Notification of application processes about exceptional situations.

6. Setting marks in the application process that allow, after a failure or error, to restore its execution from the nearest mark.

7. Interrupting the application process when necessary and resuming it correctly.

8. Terminate a session without losing data.

9. Transmission of special messages about the progress of the session.

The session layer is responsible for organizing data exchange sessions between end machines. Session layer protocols are usually a component of the top three layers of the model.

Transport Layer

The transport layer is designed to transmit packets across a communication network. At the transport layer, packets are divided into blocks.

On the way from the sender to the recipient, packets may be corrupted or lost. While some applications have their own error handling, there are others that prefer to deal with a reliable connection right away. The job of the transport layer is to ensure that applications or upper layers of the model (application and session) transfer data with the degree of reliability that they require. The OSI model defines five classes of service provided by the transport layer. These types of services are distinguished by the quality of the services provided: urgency, the ability to restore interrupted communications, the availability of means for multiplexing multiple connections between different application protocols through a common transport protocol, and most importantly, the ability to detect and correct transmission errors, such as distortion, loss and duplication of packets.

The transport layer determines addressing physical devices(systems, their parts) on the network. This layer guarantees the delivery of blocks of information to recipients and controls this delivery. Its main task is to provide efficient, convenient and reliable forms of information transfer between systems. When more than one packet is being processed, the transport layer controls the order in which the packets are processed. If a duplicate of a previously received message passes through, then this level recognizes this and ignores the message.

The functions of the transport layer include:

1. Controlling transmission over the network and ensuring the integrity of data blocks.

2. Detection of errors, their partial elimination and reporting of uncorrected errors.

3. Restoring transmission after failures and malfunctions.

4. Enlargement or division of data blocks.

5. Providing priorities when transferring blocks (normal or urgent).

6. Confirmation of transfer.

7. Elimination of blocks in case of deadlock situations in the network.

Starting from the transport layer, all higher-lying protocols are implemented in software, usually included in the network operating system.

The most common transport layer protocols include:

TCP (Transmission Control Protocol) transmission control protocol of the TCP/IP stack;

UDP (User Datagram Protocol) user datagram protocol of the TCP/IP stack;

NCP (NetWare Core Protocol) the basic protocol of NetWare networks;

SPX (Sequenced Packet eXchange) orderly exchange of Novell stack packages;

TP4 (Transmission Protocol) – class 4 transmission protocol.

Network Layer

The network level ensures the laying of channels connecting subscriber and administrative systems through the communication network, selection of the fastest and most reliable route.

The network layer establishes communication in computer network between two systems and provides the laying of virtual channels between them. A virtual or logical channel is a functioning of network components that creates the illusion of the necessary path between them for the interacting components. In addition, the network layer reports errors to the transport layer. Network layer messages are usually called packets. They contain pieces of data. The network layer is responsible for their addressing and delivery.

Finding the best path for data transmission is called routing, and its solution is the main task of the network layer. This problem is complicated by the fact that the shortest path is not always the best. Often the criterion for choosing a route is the transmission time of data along this route; it depends on the capacity of communication channels and traffic intensity, which can change over time. Some routing algorithms try to adapt to changes in load, while others make decisions based on averages over time. long time. The route can be selected based on other criteria, for example, transmission reliability.

The link layer protocol ensures the delivery of data between any nodes only in a network with the appropriate standard topology. This is a very strict limitation that does not allow building networks with a developed structure, for example, networks that combine several enterprise networks in single network, or highly reliable networks in which there are redundant connections between nodes.

Thus, within the network, data delivery is regulated by the data link layer, but data delivery between networks is handled by the network layer. When organizing packet delivery at the network level, the concept of network number is used. In this case, the recipient's address consists of the network number and the computer number on this network.

Networks are connected to each other by special devices called routers. A router is a device that collects information about the topology of internetwork connections and, based on it, forwards network layer packets to the destination network. In order to transmit a message from a sender located on one network to a recipient located on another network, you need to make a number of transit transfers (hops) between networks, each time choosing the appropriate route. Thus, a route is a sequence of routers through which a packet passes.

The network layer is responsible for dividing users into groups and routing packets based on the translation of MAC addresses to network addresses. The network layer also provides transparent transmission of packets to the transport layer.

The network layer performs the following functions:

1. Creating network connections and identifying their ports.

2. Detecting and correcting errors that occur during transmission through a communication network.

3. Packet flow control.

4. Organization (ordering) of sequences of packets.

5. Routing and switching.

6. Segmentation and merging of packages.

At the network level, two types of protocols are defined. The first type refers to the definition of rules for transmitting end node data packets from the node to the router and between routers. These are the protocols that are usually meant when people talk about network layer protocols. However, another type of protocol, called routing information exchange protocols, is often included in the network layer. Using these protocols, routers collect information about the topology of internetwork connections.

Network layer protocols are implemented software modules operating system, as well as software and hardware of routers.

The most commonly used protocols at the network level are:

IP (Internet Protocol) Internet protocol, a network protocol of the TCP/IP stack that provides address and routing information;

IPX (Internetwork Packet Exchange) is an internetwork packet exchange protocol designed for addressing and routing packets on Novell networks;

X.25 is an international standard for global packet-switched communications (partially implemented at Layer 2);

CLNP (Connection Less Network Protocol) is a connectionless network protocol.

Data Link Layer

The unit of information at the link layer is the frame. Frames are a logically organized structure into which data can be placed. The job of the link layer is to transmit frames from the network layer to the physical layer.

The physical layer simply transfers bits. This does not take into account that in some networks in which communication lines are used alternately by several pairs of interacting computers, the physical transmission medium may be occupied. Therefore, one of the tasks of the link layer is to check the availability of the transmission medium. Another task of the link layer is to implement error detection and correction mechanisms.

The link layer ensures that each frame is transmitted correctly by placing a special sequence of bits at the beginning and end of each frame to mark it, and also calculates a checksum by summing all the bytes of the frame in a certain way and adding the checksum to the frame. When the frame arrives, the receiver again calculates the checksum of the received data and compares the result with the checksum from the frame. If they match, the frame is considered correct and accepted. If the checksums do not match, an error is recorded.

The task of the link layer is to take packets coming from the network layer and prepare them for transmission, placing them in a frame of the appropriate size. This layer is responsible for determining where a block begins and ends, as well as detecting transmission errors.

At the same level, the rules for using the physical layer by network nodes are determined. The electrical representation of data on the LAN (data bits, data encoding methods, and tokens) are recognized at this level and only at this level. This is where errors are detected and corrected (by requiring data to be retransmitted).

The data link layer provides the creation, transmission and reception of data frames. This layer serves requests from the network layer and uses the physical layer service to receive and transmit packets. The IEEE 802.X specifications divide the data link layer into two sublayers:

LLC (Logical Link Control) logical link control provides logical control of communication. The LLC sublayer provides network layer services and is associated with the transmission and reception of user messages.

MAC (Media Assess Control) media access control. The MAC sublayer regulates access to the shared physical medium (token passing or collision or collision detection) and controls access to the communication channel. The LLC sublayer is located above the MAC sublayer.

The data link layer defines media access and transmission control through a procedure for transmitting data over the channel.

When the transmitted data blocks are large, the link layer divides them into frames and transmits the frames in the form of sequences.

When receiving frames, the layer forms transmitted data blocks from them. The size of a data block depends on the transmission method and the quality of the channel over which it is transmitted.

In local area networks, link layer protocols are used by computers, bridges, switches, and routers. In computers, link layer functions are implemented jointly network adapters and their drivers.

The data link layer can perform the following types of functions:

1. Organization (establishment, management, termination) of channel connections and identification of their ports.

2. Organization and transfer of personnel.

3. Detection and correction of errors.

4. Data flow management.

5. Ensuring transparency of logical channels (transmission of data encoded in any way through them).

The most commonly used protocols at the data link layer include:

HDLC (High Level Data Link Control) high-level data link control protocol for serial connections;

IEEE 802.2 LLC (Type I and Type II) provide MAC for 802.x environments;

Ethernet network technology according to the IEEE 802.3 standard for networks using bus topology and multiple access with carrier frequency listening and conflict detection;

Token ring network technology according to the IEEE 802.5 standard, using a ring topology and a ring access method with token passing;

FDDI (Fiber Distributed Date Interface Station) is a network technology according to the IEEE 802.6 standard using fiber optic media;

X.25 is an international standard for global packet-switched communications;

Frame relay network organized using X25 and ISDN technologies.

Physical Layer

The physical layer is designed to interface with physical means of communication. Physical connection means is a combination of the physical environment, hardware and software, providing signal transmission between systems.

The physical medium is the material substance through which signals are transmitted. The physical environment is the foundation on which physical connectivity is built. Ether, metals, optical glass and quartz are widely used as physical media.

The physical layer consists of a Media Interface Sublayer and a Transmission Conversion Sublayer.

The first of them ensures the pairing of the data stream with the physical communication channel used. The second one carries out transformations related to the protocols used. The physical layer provides the physical interface to the data channel and also describes the procedures for transmitting signals to and receiving signals from the channel. At this level, the electrical, mechanical, functional and procedural parameters for physical connection in systems. The physical layer receives data packets from the upper link layer and converts them into optical or electrical signals corresponding to 0 and 1 of the binary stream. These signals are sent through the transmission medium to the receiving node. Mechanical and electrical/optical properties of the transmission medium are determined at the physical level and include:

Type of cables and connectors;

Layout of contacts in connectors;

Signal coding scheme for values ​​0 and 1.

The physical layer performs the following functions:

1. Establishing and disconnecting physical connections.

2. Serial code transmission and reception.

3. Listening, if necessary, to channels.

4. Channel identification.

5. Notification of malfunctions and failures.

Notification of faults and failures is due to the fact that at the physical level a certain class of events is detected that interfere with the normal operation of the network (collision of frames sent by several systems at once, channel break, power outage, loss of mechanical contact, etc.). The types of services provided to the data link layer are determined by the physical layer protocols. Listening to a channel is necessary in cases where a group of systems are connected to one channel, but only one of them is allowed to transmit signals at the same time. Therefore, listening to a channel allows you to determine whether it is free for transmission. In some cases, for more clear definition The structure of the physical layer is divided into several sublevels. For example, the physical layer of a wireless network is divided into three sublayers (Fig. 1.14).

Rice. 1.14. Wireless LAN Physical Layer

Physical layer functions are implemented in all devices connected to the network. On the computer side, the physical layer functions are performed by the network adapter. Repeaters are the only type of equipment that operates only on the physical layer.

The physical layer can provide both asynchronous (serial) and synchronous (parallel) transmission, which is used for some mainframes and minicomputers. At the Physical Layer, an encoding scheme must be defined to represent binary values ​​for the purpose of transmitting them over a communication channel. Many local networks use Manchester encoding.

An example of a physical layer protocol is the 10Base-T Ethernet technology specification, which defines the cable used as Category 3 unshielded twisted pair with a characteristic impedance of 100 Ohms, an RJ-45 connector, a maximum physical segment length of 100 meters, Manchester code for data representation and other characteristics environment and electrical signals.

Some of the most common physical layer specifications include:

EIA-RS-232-C, CCITT V.24/V.28 – mechanical/electrical characteristics of an unbalanced serial interface;

EIA-RS-422/449, CCITT V.10 – mechanical, electrical and optical characteristics of a balanced serial interface;

Ethernet is a network technology according to the IEEE 802.3 standard for networks that uses a bus topology and multiple access with carrier listening and collision detection;

Token ring is a network technology according to the IEEE 802.5 standard, using a ring topology and a ring access method with token passing.

In today's article I want to go back to basics and talk about OSI open systems interconnection models. This material will be useful for beginners system administrators and all those who are interested in building computer networks.

All components of the network, from the data transmission medium to the equipment, function and interact with each other according to a set of rules that are described in the so-called open systems interaction models.

Open Systems Interoperability Model OSI(Open System Interconnection) was developed by the international organization according to ISO standards (International Standards Organization).

According to the OSI model, data transmitted from source to destination passes seven levels . At each level, a specific task is performed, which ultimately not only guarantees the delivery of data to the final destination, but also makes their transmission independent of the means used for this. Thus, compatibility is achieved between networks with different topologies and network equipment.

Separating all network tools into layers simplifies their development and use. The higher the level, the more complex the problem it solves. The first three layers of the OSI model ( physical, channel, network) are closely related to the network and the network equipment used. The last three levels ( session, data presentation layer, application) are implemented using the operating system and application programs. Transport layer acts as an intermediary between these two groups.

Before being sent over the network, the data is split into packages , i.e. pieces of information organized in a specific way so that they are understandable to receiving and transmitting devices. When sending data, the packet is sequentially processed by means of all levels of the OSI model, from application to physical. At each level, control information for that level (called packet header ), which is necessary for successful data transfer over the network.

As a result, this network message begins to resemble a multi-layer sandwich, which must be “edible” for the computer that receives it. To do this, it is necessary to adhere to certain rules for data exchange between networked computers. These rules are called protocols .

On the receiving side, the packet is processed by means of all layers of the OSI model in the reverse order, starting with the physical and ending with the application. At each level, the corresponding means, guided by the layer's protocol, read the packet information, then remove the information added to the packet at the same level by the sending side, and transmit the packet to the next level. When the packet reaches the application layer, all control information will be removed from the packet, and the data will return to its original form.

Now let's look at the operation of each layer of the OSI model in more detail:

Physical layer – the lowest one, behind it there is directly a communication channel through which information is transmitted. He participates in organizing communications, taking into account the characteristics of the data transmission medium. Thus, it contains all the information about the data transmission medium: signal level and frequency, presence of interference, level of signal attenuation, channel resistance, etc. In addition, it is he who is responsible for transmitting the flow of information and transforming it in accordance with existing methods coding. The work of the physical layer is initially assigned to the network equipment.
It is worth noting that it is with the help of the physical layer that the wired and wireless network. In the first case, cable is used as the physical medium, in the second - any type wireless communication, such as radio waves or infrared radiation.

Data Link Layer performs the most difficult task - ensures guaranteed data transmission using physical layer algorithms and verifies the correctness of the received data.

Before initiating data transfer, the availability of the transmission channel is determined. Information is transmitted in blocks called personnel , or frames . Each such frame is provided with a sequence of bits at the end and beginning of the block, and is also supplemented with a checksum. When receiving such a block at the link layer, the recipient must check the integrity of the block and compare the received checksum with the checksum included in it. If they match, the data is considered correct, otherwise an error is recorded and retransmission is required. In any case, a signal is sent to the sender with the result of the operation, and this happens with each frame. Thus, the second important task of the link layer is checking the correctness of the data.

The data link layer can be implemented both in hardware (for example, using switches) and using software (for example, a network adapter driver).

Network layer necessary to perform data transfer work with preliminary determination of the optimal path for packets to move. Since a network can consist of segments with different topologies, the main task of the network layer is to determine the shortest path, simultaneously converting the logical addresses and names of network devices into their physical representation. This process is called routing , and its importance cannot be overestimated. Having a routing scheme that is constantly updated due to the occurrence of various kinds of “congestion” in the network, data transfer is carried out in the shortest possible time and at maximum speed.

Transport layer used to organize reliable data transmission, which eliminates the loss of information, its incorrectness or duplication. At the same time, compliance with the correct sequence when transmitting and receiving data is monitored, dividing them into smaller packets or combining them into larger ones to maintain the integrity of the information.

Session layer is responsible for creating, maintaining and maintaining a communication session for the time necessary to complete the transfer of the entire amount of data. In addition, it synchronizes the transmission of packets by checking the delivery and integrity of the packet. During the data transfer process, special control points are created. If there is a failure during transmission and reception, the missing packets are sent again, starting from the nearest control point, which allows you to transfer the entire amount of data in the shortest possible time, providing generally good speed.

Data presentation layer (or, as it is also called, executive level ) is intermediate, its main task is to convert data from a format for transmission over a network into a format understandable to a higher level, and vice versa. In addition, it is responsible for bringing data to a single format: when information is transferred between two absolutely different networks with different data formats, then before processing them, it is necessary to bring them to a form that will be understandable to both the recipient and the sender. It is at this level that encryption and data compression algorithms are used.

Application layer – the last and highest in the OSI model. Responsible for connecting the network with users - applications that require information from network services at all levels. With its help, you can find out everything that happened during the data transfer process, as well as information about errors that occurred during the transfer process. In addition, this level ensures the operation of all external processes carried out through access to the network - databases, mail clients, file download managers, etc.

On the Internet, I found a picture in which an unknown author presented OSI network model in the form of a burger. I think this is a very memorable image. If suddenly in some situation (for example, during a job interview) you need to list all seven layers of the OSI model in the correct order from memory - just remember this picture, and this will help you. For convenience, I translated the names of the levels from English into Russian: That's all for today. In the next article I will continue the topic and talk about.

Share