Your IP: Unknown · Your Status: ProtectedUnprotectedUnknown

Skip to main content

OSI model: 7 OSI layers explained

OSI is a conceptual framework for discussing and troubleshooting network problems. The modern internet is based on the TCP/IP model, but OSI’s seven-layer system is still commonly used to visualize and engage with networking issues. In this article, we’ll explain how the OSI model works and detail its seven layers.

OSI model: 7 OSI layers explained

What is the OSI model?

The Open Systems Interconnection (OSI) model is a universal language for computer networking. The OSI model was published in 1984 by the International Organization for Standardization (ISO). The model consists of seven theoretical layers of systems and protocols, and this conceptualization can be applied to almost any networking process.

Two networks are likely to operate in different ways, but the OSI model can be applied regardless of the specific systems at play in a given network. In theory, it’s a way to think and talk about networks that isn’t network-specific.

The OSI model visualizes networks as seven-layer structures, ranging from the foundational application layer to the uppermost physical layer.

What is the OSI seven-layer model?

In OSI’s seven-layer concept, each layer has a specific function to perform. When all the individual layers of the OSI model work correctly, the network as a whole is functional and effective. If a problem arises across a network, an engineer can use the OSI model to isolate the problem to a specific layer. The layers are listed below, from the lowest (the transport layer) to the highest (the physical layer).

  • Application layer
  • Presentation layer
  • Session layer
  • Transport layer
  • Network layer
  • Data link layer
  • Physical layer

We’ll now walk you through each of the seven layers and their functions.

7: Application layer

The application layer represents the protocols that allow for data transfer to and from user applications. We should clarify that the application layer doesn’t actually include the applications themselves (like web browsers) but instead focuses on the protocols used by applications (like HTTP, DNS, and SMTP).

6: Presentation layer

At the presentation layer, data is made presentable and readable for the receiver. Data is translated into a language and format that can be transmitted at the application level. If information is being sent through an encrypted network, the presentation layer is where encryption and decryption occurs. Presentation processes are essential to allow different computer systems and network services to communicate smoothly, even if they rely on different syntax and encoding methods.

5: Session layer

The fifth layer is responsible for sessions: temporary channels of communication between devices. Sessions remain open only as long as the data transfer is taking place. Once all the information has been transmitted from one device to another, the session closes. Systems at the session layer can also generate checkpoints, markers that are created at regular intervals in the transfer (every 10gb, for example). If the connection is lost and then reestablished, the session can pick up where it left off thanks to the checkmarks.

4: Transport layer

As its name suggests, the transport layer is where information is transported across a network. At this level, the data being moved is first broken down into small segments. These are then transmitted individually to the destination and reassembled there. All processes involved in segmentation, transmission, and reassembly take place on the transport layer. Incidentally, when hackers launch DDoS attacks, they often do so at the transport layer.

3: Network layer

The network layer breaks data up into smaller pieces to facilitate fast, efficient data transport. The data segments (passed to the network layer from the transport layer) are divided into even smaller fragments, known as data packets. As well as managing the division and assembly of data packets, network layer protocols search out the fastest possible route by which the packets can travel.

2: Data link layer

If two devices are on the same network, their communication involves the data link layer. Processes at this level include the establishment of connections across a local network, the division of data packets into frames (even smaller fragments of data), and the transmission of frames between devices. Even if you’re connecting to a device on another network, the data link layer will be involved when your data is moving between your device (a smartphone or laptop, for example) and your internet gateway.

1: Physical layer

The physical layer is responsible for all the hardware needed during networking. Cables, switches, and devices fall into this category. Also included in the physical layer are the protocols that convert data into strings of 1s and 0s. In this format (called a bit stream) the information can be sent to its intended destination, where it is received and translated by other layers, like the presentation and application layers.

How does data flow through the OSI model?

To understand how data flows through the OSI model layers, let’s imagine that you want to send an email to a friend. You open an email application on your laptop (which is part of the physical layer), write a message, and click “send.”

The application moves your data (the email and any relevant information about its intended recipient) into the application layer, where the SMTP protocol transfers it to the presentation layer. Here the data is compressed, making it faster and more efficient to transfer, before it goes to the session layer.

A session is now opened between your laptop and the receiving device. Before it can be moved further, the compressed data transitions to your transportation layer. The data is broken into segments and these segments into packets. The packets must move from your device to the internet gateway (your router), and while doing so they move through the data link layer as frames. The network layer is also effective during this part of the process because it routes the data.

The data reaches the physical layer. After being translated into 1s and 0s, it travels through physical structures (fiber optic cables, for example). When the data reaches your friend’s internet gateway, the process we’ve just described plays out in reverse as the frames, packets, and segments are reassembled, made readable, and rendered through your friend’s email application. At this point, the session layer deactivates the communication channel between your devices.

OSI model vs. TCP/IP Model

The Transmission Control Protocol/Internet Protocol, or TCP/IP, is a more widely used framework than the Open Systems Interconnection model. TCP/IP was invented by the Department of Defense in the US and predates OSI.

TCP/IP is simpler than OSI because it combines several OSI layers into one. For example, layers 5, 6, and 7 in OSI are all considered to be part of one application layer in TCP/IP.

Another important distinction is the models’ protocol specificity. TCP/IP is designed to work around several standard, commonly used protocols, while the OSI model is intended to be protocol-agnostic.

Why is the OSI model used? Is it still relevant?

The OSI model is not redundant, even if it isn’t used as much as TCP/IP. The model offers several notable benefits, and can help with application security and error resolution.

For one thing, being able to isolate a networking problem to a specific layer among seven makes troubleshooting more effective. The fact that TCP/IP collapses several layers into one might appear simpler at first, but it makes it slightly harder to track down and define technical problems than it would be in OSI.

OSI also benefits from its universality. As a conceptual framework, it works with any network and doesn’t rely on the use of specific protocols to be relevant. This makes it a helpful tool for engineers and network security experts when discussing and assessing network errors.