The data link layer is the second layer of the OSI model and re­spons­ible for bits being sent correctly in the form of data packets. It not only looks after por­tion­ing and mon­it­or­ing during the transfer, it’s also actively involved in troubleshoot­ing.

What is the OSI data link layer?

The data link layer is the second layer in the OSI model. This con­cep­tu­al model struc­tures the processes needed by computers and network tech­no­logy to allow com­mu­nic­a­tion across hardware and software. Within this model, the data link layer works as a protocol layer and ensures frames are trans­ferred correctly within a physical con­nec­tion.

The OSI reference model is split into seven different layers that are built one on top of the other. Each layer has its own specific tasks. The in­di­vidu­al layers are as follows:

  1. Physical layer
  2. Data link layer
  3. Network layer
  4. Transport layer
  5. Session layer
  6. Present­a­tion layer
  7. Ap­plic­a­tion layer

What does the data link layer do?

To un­der­stand what functions the data link layer has, it’s necessary to first take a look at the layer below it. In the physical layer, physical con­nec­tions between two systems are activated, monitored and de­ac­tiv­ated. This means that data can be sent from a sender to a receiver. This layer does not, however, evaluate the data. It simply transfers it without checking its content or structure.

This is where the data link layer comes in. It codifies, de­co­di­fies and organises the in­di­vidu­al bits and then prepares them as data frames. This means that it creates data packets, turning larger data packets into smaller units.

The data is then forwarded from the data link layer to the network layer, the layer situated directly above it. In the network layer, it is then given an address and forwarded on. The data link layer ensures that the frames are trans­ferred without any errors and, therefore, makes unsecured system con­nec­tions secure.

The com­mu­nic­a­tion which takes place on the data link layer can be carried out with or without a con­nec­tion. If a con­nec­tion is not present, all data which is to be trans­ferred will contain a source and target address. However, if a con­nec­tion is being used, logical con­nec­tions between the sender and the receiver will be es­tab­lished first.

How does the data link layer troubleshoot?

In addition to the tasks mentioned above, the data link layer is also re­spons­ible for checking frames during and after data transfer as well as identi­fy­ing and cor­rect­ing any errors. To do this, it first analyses the bit pattern within the frame so it can detect problems and errors early on.

If there is an ir­reg­u­lar­ity, the data link layer informs the layers above it. The receiver can then re-sort the frames if they were delivered in the wrong order. Meanwhile, the data link layer checks to see whether the in­di­vidu­al packets have remained intact.

To do this, the OSI data link layer examines the data flow to see if a physical con­nec­tion is over­loaded and then in­ter­venes ac­cord­ingly. If there are any lim­it­a­tions, this in­form­a­tion is sent to devices nearby and, if possible, rerouted.

Which services does the data link layer carry out?

The data link layer is broken down into two sublayers: The logical MAC (Medium Access Control) is adjacent to the physical layer (1) and the LLC (Logical Link Control) connects to the network layer (Layer 3). The services provided by the data link layer can be separated into three cat­egor­ies:

Con­nec­tion­less services without con­firm­a­tion

If frames are sent using this method, the recipient will provide no con­firm­a­tion, even if frames have been received as intended. If data packets are damaged or get lost, there is no res­tor­a­tion. This type of transfer is, therefore, only suitable for ex­cep­tion­ally secure con­nec­tions or if a higher level can troubleshoot. This method can be used when instant data transfer is needed and is more important than a complete transfer.

Con­nec­tion­less services with con­firm­a­tion

In most cases, this type of transfer is preferred since each transfer is confirmed. If a transfer does not reach its specified location or some parts of it get lost, there will be no con­firm­a­tion, and the data transfer should be started again. This ensures that all frames reach the receiver.

Con­nec­tion-oriented services

The most secure method is using con­nec­tion-oriented services. This gives each data packet a specific number, which is logged at both the sender and receiver’s end. These then connect before every transfer. Both sides are thus able to ensure that every packet is trans­ferred just once and reaches its des­tin­a­tion without errors.

Data link layer protocols

There are many data link layer protocols. These include among others:

Go to Main Menu