What is the OSI network model. OSI Model Layers

It is definitely better to start with theory, and then gradually move on to practice. Therefore, first we will consider the network model (theoretical model), and then we will lift the curtain on how the theoretical network model fits into the network infrastructure (network equipment, user computers, cables, radio waves, etc.).

So, network model is a model of interaction between network protocols. And protocols, in turn, are standards that determine how different programs will exchange data.

Let me explain with an example: when opening any page on the Internet, the server (where the page being opened is located) sends data (a hypertext document) to your browser via the HTTP protocol. Thanks to the HTTP protocol, your browser, receiving data from the server, knows how it needs to be processed, and successfully processes it, showing you the requested page.

If you don’t yet know what a page on the Internet is, then I’ll explain in a nutshell: any text on a web page is enclosed in special tags that tell the browser what text size to use, its color, location on the page (left, right, or in the center). This applies not only to text, but also to pictures, forms, active elements and generally all content, i.e. what is on the page. The browser, detecting the tags, acts according to their instructions, and shows you the processed data that is enclosed in these tags. You yourself can see the tags of this page (and this text between the tags), to do this, go to the menu of your browser and select - view source code.

Let’s not get too distracted, “Network Model” is a necessary topic for those who want to become a specialist. This article consists of 3 parts and for you, I tried to write it not boringly, clearly and briefly. For details, or for additional clarification, write in the comments at the bottom of the page, and I will certainly help you.

We, as in the Cisco Networking Academy, will consider two network models: the OSI model and the TCP/IP model (sometimes called DOD), and at the same time compare them.

OSI stands for Open System Interconnection. In Russian it sounds like this: Network model of interaction of open systems (reference model). This model can be safely called a standard. This is the model that network device manufacturers follow when developing new products.

The OSI network model consists of 7 layers, and it is customary to start counting from the bottom.

Let's list them:

  • 7. Application layer
  • 6. Presentation layer
  • 5. Session layer
  • 4. Transport layer
  • 3. Network layer
  • 2. Data link layer
  • 1. Physical layer

As mentioned above, the network model is a model of interaction between network protocols (standards), and each level has its own protocols. It’s a boring process to list them (and there’s no point), so it’s better to look at everything using an example, because the digestibility of the material is much higher with examples;)

Application layer

The application layer or application layer is the topmost level of the model. It communicates user applications with the network. These applications are familiar to us all: web browsing (HTTP), sending and receiving mail (SMTP, POP3), receiving and receiving files (FTP, TFTP), remote access (Telnet), etc.

Executive level

Presentation layer or presentation layer – it converts data into the appropriate format. It’s easier to understand with an example: those pictures (all images) that you see on the screen are transmitted when sending a file in the form of small portions of ones and zeroes (bits). So, when you send a photo to your friend via email, the SMTP Application Layer protocol sends the photo to the lower layer, i.e. to the Presentation level. Where your photo is converted into a convenient form of data for lower levels, for example into bits (ones and zeros).

In exactly the same way, when your friend starts receiving your photo, it will come to him in the form of the same ones and zeros, and it is the Presentation layer that converts the bits into a full-fledged photo, for example, a JPEG.

This is how this level works with protocols (standards) for images (JPEG, GIF, PNG, TIFF), encodings (ASCII, EBDIC), music and video (MPEG), etc.

Session layer

Session layer or session layer - as the name suggests, it organizes a communication session between computers. A good example would be audio and video conferencing; at this level it is established which codec the signal will be encoded with, and this codec must be present on both machines. Another example is the SMPP (Short message peer-to-peer protocol), which is used to send well-known SMS and USSD requests. One last example: PAP (Password Authentication Protocol) is an old protocol for sending a username and password to a server without encryption.

I won’t say anything more about the session level, otherwise we’ll delve into the boring features of the protocols. And if they (features) interest you, write letters to me or leave a message in the comments asking me to expand on the topic in more detail, and a new article will not be long in coming;)

Transport layer

Transport layer - this layer ensures the reliability of data transmission from sender to recipient. In fact, everything is very simple, for example, you communicate using a webcam with your friend or teacher. Is there a need for reliable delivery of every bit of the transmitted image? Of course not, if a few bits are lost from the streaming video, you won’t even notice it, not even the picture will change (maybe the color of one pixel out of 900,000 pixels will change, which will flash at a speed of 24 frames per second).

Now let’s give this example: a friend sends you (for example, via mail) important information or a program in an archive. You download this archive to your computer. This is where 100% reliability is needed, because... if a couple of bits are lost when downloading the archive, you will not be able to unzip it, i.e. extract the necessary data. Or imagine sending a password to a server, and one bit gets lost along the way - the password will already lose its appearance and the meaning will change.

So, when we watch videos on the Internet, sometimes we see some artifacts, delays, noise, etc. And when we read text from a web page, the loss (or distortion) of letters is not acceptable, and when we download programs, everything also goes without errors.

At this level I will highlight two protocols: UDP and TCP. The UDP protocol (User Datagram Protocol) transfers data without establishing a connection, does not confirm the delivery of data and does not make repetitions. TCP protocol (Transmission Control Protocol), which before transmission establishes a connection, confirms the delivery of data, repeats it if necessary, and guarantees the integrity and correct sequence of the downloaded data.

Therefore, for music, video, video conferencing and calls we use UDP (we transfer data without verification and without delays), and for text, programs, passwords, archives, etc. – TCP (data transmission with confirmation of receipt takes more time).

Network layer

Network layer - this layer determines the path along which data will be transmitted. And, by the way, this is the third level of the OSI Network Model, and there are devices that are called third-level devices - routers.

We have all heard about the IP address, this is what the IP (Internet Protocol) protocol does. An IP address is a logical address on a network.

There are quite a lot of protocols at this level, and we will examine all of these protocols in more detail later, in separate articles and with examples. Now I’ll just list a few popular ones.

Just like everyone has heard about the IP address and the ping command, this is how the ICMP protocol works.

The same routers (with which we will work in the future) use protocols of this level to route packets (RIP, EIGRP, OSPF).

Data Link Layer

Data link layer – we need it for the interaction of networks at the physical level. Probably everyone has heard about the MAC address; it is a physical address. Link layer devices - switches, hubs, etc.

IEEE (Institute of Electrical and Electronics Engineers) defines the data link layer as two sublayers: LLC and MAC.

LLC – Logical Link Control, created to interact with the upper level.

MAC – Media Access Control, created to interact with the lower level.

I’ll explain with an example: your computer (laptop, communicator) has a network card (or some other adapter), and so there is a driver to interact with it (with the card). A driver is some program- the upper sublayer of the channel layer, through which it is possible to communicate with the lower levels, or rather with the microprocessor ( iron) – lower sublayer of the data link layer.

There are many typical representatives at this level. PPP (Point-to-Point) is a protocol for connecting two computers directly. FDDI (Fiber Distributed Data Interface) - the standard transmits data over a distance of up to 200 kilometers. CDP (Cisco Discovery Protocol) is a proprietary protocol owned by Cisco Systems, which can be used to discover neighboring devices and obtain information about these devices.

Physical layer

Physical layer is the lowest level that directly transfers the data stream. The protocols are well known to us all: Bluetooth, IRDA (Infrared communication), copper wires (twisted pair, telephone line), Wi-Fi, etc.

Conclusion

So we looked at the OSI network model. In the next part, we will move on to the TCP/IP Network model, it is smaller and the protocols are the same. To successfully pass the CCNA tests, you need to make a comparison and identify the differences, which will be done.

To harmonize the operation of network devices from different manufacturers and ensure the interaction of networks that use different signal propagation environments, a reference model of open systems interaction (OSI) has been created. The reference model is built on a hierarchical principle. Each level provides services to the higher level and uses the services of the lower level.

Data processing begins at the application level. After this, the data passes through all layers of the reference model, and is sent through the physical layer to the communication channel. At reception, reverse processing of the data occurs.

The OSI reference model introduces two concepts: protocol And interface.

A protocol is a set of rules on the basis of which the layers of various open systems interact.

An interface is a set of means and methods of interaction between elements of an open system.

The protocol defines the rules for interaction between modules of the same level in different nodes, and the interface - between modules of adjacent levels in the same node.

There are a total of seven layers of the OSI reference model. It's worth noting that real stacks use fewer layers. For example, the popular TCP/IP uses only four layers. Why is this so? We'll explain a little later. Now let’s look at each of the seven levels separately.

OSI Model Layers:

  • Physical level. Determines the type of data transmission medium, the physical and electrical characteristics of the interfaces, and the type of signal. This layer deals with bits of information. Examples of physical layer protocols: Ethernet, ISDN, Wi-Fi.
  • Data link level. Responsible for access to the transmission medium, error correction, and reliable data transmission. At the reception The data received from the physical layer is packed into frames and then their integrity is checked. If there are no errors, then the data is transferred to the network layer. If there are errors, the frame is discarded and a request for retransmission is generated. The data link layer is divided into two sublayers: MAC (Media Access Control) and LLC (Local Link Control). MAC regulates access to the shared physical medium. LLC provides network layer service. Switches operate at the data link layer. Examples of protocols: Ethernet, PPP.
  • Network layer. Its main tasks are routing - determining the optimal data transmission path, logical addressing of nodes. In addition, this level may be tasked with troubleshooting network problems (ICMP protocol). The network layer works with packets. Examples of protocols: IP, ICMP, IGMP, BGP, OSPF).
  • Transport layer. Designed to deliver data without errors, losses and duplication in the sequence in which they were transmitted. Performs end-to-end control of data transmission from sender to recipient. Examples of protocols: TCP, UDP.
  • Session level. Manages the creation/maintenance/termination of a communication session. Examples of protocols: L2TP, RTCP.
  • Executive level. Converts data into the required form, encrypts/encodes, and compresses.
  • Application layer. Provides interaction between the user and the network. Interacts with client-side applications. Examples of protocols: HTTP, FTP, Telnet, SSH, SNMP.

After getting acquainted with the reference model, let's look at the TCP/IP protocol stack.

There are four layers defined in the TCP/IP model. As can be seen from the figure above, one TCP/IP layer can correspond to several layers of the OSI model.

TCP/IP model levels:

  • Network interface level. Corresponds to the two lower layers of the OSI model: data link and physical. Based on this, it is clear that this level determines the characteristics of the transmission medium (twisted pair, optical fiber, radio), the type of signal, coding method, access to the transmission medium, error correction, physical addressing (MAC addresses). In the TCP/IP model, the Ethrnet protocol and its derivatives (Fast Ethernet, Gigabit Ethernet) operate at this level.
  • Interconnection layer. Corresponds to the network layer of the OSI model. Takes over all its functions: routing, logical addressing (IP addresses). The IP protocol operates at this level.
  • Transport layer. Corresponds to the transport layer of the OSI model. Responsible for delivering packets from source to destination. At this level, two protocols are used: TCP and UDP. TCP is more reliable than UDP by creating pre-connection requests to retransmit when errors occur. However, at the same time, TCP is slower than UDP.
  • Application layer. Its main task is to interact with applications and processes on hosts. Examples of protocols: HTTP, FTP, POP3, SNMP, NTP, DNS, DHCP.

Encapsulation is a method of packaging a data packet in which independent packet headers are abstracted from the headers of lower levels by including them in higher levels.

Let's look at a specific example. Let's say we want to get from a computer to a website. To do this, our computer must prepare an http request to obtain the resources of the web server on which the site page we need is stored. At the application level, an HTTP header is added to the browser data. Next, at the transport layer, a TCP header is added to our packet, containing the sender and recipient port numbers (port 80 for HTTP). At the network layer, an IP header is generated containing the IP addresses of the sender and recipient. Immediately before transmission, an Ethrnet header is added at the link layer, which contains the physical (MAC addresses) of the sender and recipient. After all these procedures, the packet in the form of bits of information is transmitted over the network. At the reception, the reverse procedure occurs. The web server at each level will check the corresponding header. If the check is successful, the header is discarded and the packet moves to the upper level. Otherwise, the entire packet is discarded.


Subscribe to our

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 different 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 APIs (Application Programming Interfaces).

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 of 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 provides a brief description of the functions of all levels.

Rice. 1.13. Functions of the OSI Model Layers

The model under consideration determines the interaction of open systems from different manufacturers in 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 through which network users access shared resources, such as files, printers, or hypertext Web pages, and also organize their collaboration, for example, using the electronic mail protocol. 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 layer are file transfer, email messaging, 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 different types of computers (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 the application layer protocols of 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 usually an integral part of the protocols at the top three layers 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 the addressing of physical devices (systems, their parts) in 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, this layer 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 a computer network between two systems and ensures the laying of virtual channels between them. A virtual or logical channel is the 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 long-term averages. 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 into a 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 by operating system software modules, as well as router software and hardware.

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 through the joint efforts of 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 is a 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 connectivity is a set of physical media, hardware and software that enables the transmission of signals 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. This level defines the electrical, mechanical, functional and procedural parameters for physical communication 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, to more clearly define the structure, 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.

interaction of open systems. In other words, this is a certain standard by which network technologies operate.

The mentioned system consists of seven layers of the OSI model. Each protocol works with the protocols of its layer, either a layer below or above itself.

Each level operates on a specific data type:

  1. Physical - bit;
  2. Channel - frame;
  3. Network - package;
  4. Transport - segments/datagrams;
  5. Sessional - session;
  6. Executive - flow;
  7. Application - data

OSI Model Layers

Application layer ( application layer)

This is the top one OSI network model layer. It is also called the application layer. Designed for user interaction with the network. The layer provides applications with the ability to use various network services.

Functions:

  • remote access;
  • postal service;
  • generation of requests to the next level ( presentation layer)

Network layer protocols:

  • BitTorrent
  • HTTP
  • SMTP
  • SNMP
  • TELNET

Presentation layer ( presentation layer)

This is the second level. Otherwise called the executive level. Designed for protocol conversion, as well as for data encoding and decoding. At this stage, requests delivered from the application layer are formed into data for transmission over the network and vice versa.

Functions:

  • data compression/decompression;
  • data encoding/decoding;
  • redirection of requests

Network layer protocols:

  • LPP
  • NDR

Session level ( session layer)

This OSI network model layer is responsible for maintaining the communication session. Thanks to this layer, applications can interact with each other over time.

Functions:

  • granting rights
  • creating/pausing/restoring/terminating a connection

Network layer protocols:

  • ISO-SP
  • L2TP
  • NetBIOS
  • PPTP
  • SMPP

Transport layer ( transport layer)

This is the fourth level, if you count from above. Designed for reliable data transmission. However, transmission may not always be reliable. Duplication and non-delivery of data parcels are possible.

Network layer protocols:

  • UDP
  • SST
  • RTP

Network layer ( network layer)

Given OSI network model layer is responsible for determining the best and shortest route for data transmission.

Functions:

  • address assignment
  • collision tracking
  • route determination
  • switching

Network layer protocols:

  • IPv4/IPv6
  • CLNP
  • IPsec
  • R.I.P.
  • OSPF

Link layer ( Data Link layer)

This is the sixth level, which is responsible for delivering data between devices that are located in the same network area.

Functions:

  • Hardware-level addressing
  • error control
  • bug fixes

Network layer protocols:

  • SLIP
  • LAPD
  • IEEE 802.11 wireless LAN,
  • FDDI
  • ARCnet

Physical layer ( physical layer)

Lowest and most recent OSI network model layer. Used to define the method of data transmission in the physical/electrical environment. Let's say any site, for example " play online casino http://bestforplay.net ", located on some kind of server, the interfaces of which also transmit some kind of electrical signal through cables and wires.

Functions:

  • determining the type of data transfer
  • data transfer

Network layer protocols:

  • IEEE 802.15 (Bluetooth)
  • 802.11Wi-Fi
  • GSMUm radio interface
  • ITU and ITU-T
  • EIARS-232

Table of the 7-layer OSI model

OSI model
Data type Level Functions
Data Applied Access to network services
Flow Executive Data representation and encryption
Sessions Session Session management
Segments/Datagrams Transport Direct communication between endpoints and reliability
Packages Network Route determination and logical addressing
Personnel Duct Physical addressing
Bits Physical Working with transmission media, signals and binary data
access to the network environment. At the same time, link layer manages the process of placing transmitted data in the physical environment. That's why link layer divided into 2 sublevels (Fig. 5.1): upper sublevel control of the logical data transmission channel( Logical Link Control - LLC), which is common to all technologies, and the lower sublevel media access control(Media Access Control - MAC). In addition, link layer tools allow you to detect errors in transmitted data.


Rice. 5.1.

The interaction of local network nodes occurs on the basis of link level protocols. Data transmission in local networks occurs over relatively short distances (inside buildings or between closely located buildings), but at high speed (10 Mbit/s - 100 Gbit/s). Distance and transmission speed data is determined by the equipment of the corresponding standards.

International Institute of Electrical and Electronics Engineers - IEEE) the 802.x family of standards was developed, which regulates the functioning of the data link and physical layers of the seven-layer ISO/OSI model. A number of these protocols are common to all technologies, for example the 802.2 standard; other protocols (for example, 802.3, 802.3u, 802.5) define the features of local network technologies.

LLC sublayer being implemented software. At the LLC sublayer, there are several procedures that allow you to establish or not establish communication before transmitting frames containing data, to restore or not to restore frames if they are lost or errors are detected. Sublevel LLC implements communication with network layer protocols, usually with the IP protocol. Communication with the network layer and the definition of logical procedures for transmitting frames over the network implements the 802.2 protocol. The 802.1 protocol provides a general definition of local area networks, related to the ISO/OSI model. There are also modifications of this protocol.

The MAC sublayer determines the features of access to the physical medium when using various local network technologies. Each MAC layer technology (each protocol: 802.3, 802.3u, 802.3z, etc.) corresponds to several variants of physical layer specifications (protocols) (Fig. 5.1). Specification MAC layer technology - defines the physical layer environment and the basic parameters of data transfer ( transmission speed, type of medium, narrowband or broadband).

At the link level of the transmitting side, it is formed frame, in which package is encapsulated. The encapsulation process adds a frame header and trailer to a network protocol packet, such as IP. Thus, the frame of any network technology consists of three parts:

  • header,
  • data fields where the package is located,
  • limit switch.

On the receiving side, the reverse decapsulation process is implemented when a packet is extracted from the frame.

Heading includes frame delimiters, address and control fields. Separators frames allow you to determine the beginning of a frame and ensure synchronization between the transmitter and receiver. Addresses link layer are physical addresses. When using Ethernet-compatible technologies, data addressing in local networks is carried out by MAC addresses, which ensure delivery of the frame to the destination node.

End cap contains a checksum field ( Frame Check Sequence - FCS), which is calculated when transmitting a frame using a cyclic code CRC. On the receiving side checksum frame is calculated again and compared with the received one. If they match, then they consider that the frame was transmitted without errors. If the FCS values ​​diverge, the frame is discarded and must be retransmitted.

When transmitted over a network, a frame sequentially passes through a number of connections characterized by different physical environments. For example, when transmitting data from Node A to Node B (Fig. 5.2), the data sequentially passes through: the Ethernet connection between Node A and Router A (copper, unshielded twisted pair), the connection between Routers A and B (fiber optic cable), a point-to-point serial copper cable between Router B and the wireless access point WAP, a wireless connection (radio link) between the WAP and end Node B. Therefore each connection has its own frame specific format.


Rice. 5.2.

The packet prepared by Node A is encapsulated into a local network frame, which is transmitted to Router A. The router decapsulates the packet from the received frame, determines which output interface to send the packet to, then forms a new frame for transmission over the optical medium. Router B decapsulates the packet from the received frame, determines which egress interface to forward the packet to, then generates a new frame for transmission over the point-to-point serial copper medium. The wireless access point WAP, in turn, forms its own frame for transmitting data over the radio channel to the end Node B.

When creating networks, various logical topologies are used that determine how nodes communicate across the medium, how access control by Wednesday. The most well-known logical topologies are point-to-point, multiaccess, broadcast and token passing.

Sharing the environment between multiple devices is implemented based on two main methods:

  • method competitive (non-deterministic) access(Content-based Access), when all network nodes have equal rights, the order of data transmission is not organized. To transmit, this node must listen to the medium; if it is free, then information can be transmitted. In this case, conflicts may arise ( collisions) when two (or more) nodes simultaneously begin transmitting data;
  • method controlled (deterministic) access(Controlled Access), which provides nodes with priority access to the medium for data transmission.

In the early stages of the creation of Ethernet networks, a “bus” topology was used; a shared data transmission medium was common to all users. In this case, the method was implemented multiple access to a common transmission medium (802.3 protocol). This required carrier control, the presence of which indicated that some node was already transmitting data over a common medium. Therefore, a node wishing to transfer data had to wait for the end of the transfer and, when the medium was freed, try to transfer the data.

The information transmitted to the network can be received by any computer whose NIC network adapter address matches the destination MAC address of the transmitted frame, or by all computers on the network during broadcast transmission. However, only one node can transmit information at any time. Before transmitting, a node must ensure that the common bus is free by listening to the medium.

When two or more computers transmit data at the same time, a conflict occurs ( collision) when the data of transmitting nodes overlap each other, distortion occurs and loss of information. Therefore, collision processing and retransmission of the frames involved in the collision are required.

Similar method non-deterministic(associative) access by Wednesday received the name Multiple Media Access with Carrier Sense and Collision Detection( Carrier Sense Multiply Access