Back in the days, when I started studying networking, it didn’t take long before coming across the OSI Model and very quickly, I got overwhelmed! I just couldn’t see the point of it and, to be honest, I ended up memorising it without fully understanding it.
If you are going through that same trouble, I am hoping this blog will give you another start.
WHAT IS THE OSI MODEL
Historically, the OSI model represents an evolution from the original DoD model, published in 1970.
However another representation of the OSI Model exists as it applies to the TCP/IP protocol stack; it is referred to, as the TCP/IP Model and it includes four layers only.
As with any model, it normally helps if we put them into a more practical context. So let’s do that …
END-to-END = PROCESS-to-PROCESS
A network device doesn’t need to provide functionality at all layers; in fact, we often hear people say that specific devices, work at specific layers only.
For example, in the past, switches were known to work at L2 – providing switching functionality only. But for long time we’ve had switches that operate at L3 – providing routing functions as well. We also have L7 firewalls – these can inspect Layer7 protocol packets such as HTTP, SMTP, etc.
End-to-end communication does not necessarily mean that two devices are involved, as long as the same device implement both the client and the server side processes. An example of this is, connecting your local browser to a web server hosting pages on the local machine. In this case, the local machine implements both the server component (the web server process) and the client component (the web browser).
ENCAPSULATION / DECAPSULATION
So you write a letter to your friend; put it in an envelope, write the destination address on it and lastly, you take it to the post office. At the post office, all letters ready to be sent out are then boxed up and sent to a dispatch office. This process continues through different delivery layers until you eventually get the letter delivered to your friend’s home. Your friend opens the envelope and reads the letter.
This process is very similar to how data flows from source to destination. Encapsulation is the process by which data is formatted (packaged) as it travels through the different OSI layers; the reverse process is known as Decapsulation.
The diagram below illustrates these two processes.
Notice the following:
- Encapsulation is done top-down
- Decapsulation occurs bottom-up
END-TO-END IN A NUTSHELL
The following diagram illustrates network connectivity between different hosts implementing processes at different OSI layers:
- The host encapsulates the user’s data, from L7 (user-data), all the way down to L1 (bits); bits get converted into electrical signals by the network card;
- The switch converts the electrical signals back into bits and decodes the information into a L2 frame through decapsulation. It identifies the outgoing interface (switching decision) and again, encapsulates the L2 frame into bits which in turn, get converted into electrical signals;
- The router converts the electrical signals back into bits and decodes the information into a L2 frame; it further decapsulates the frame to reveal the L3 packet. It can then make a routing decision based on the destination IP address. The packet is now encapsulated back into the original L2 frame and further encoded into bits, and into electrical signals;
- The remote router goes through a similar process as above (3)
- The remote switch converts the electrical signals back into bits and decodes the information into a L2 frame through decapsulation. It identifies the outgoing interface (switching decision) and once again, encapsulates the L2 frame into bits which in turn, get converted into electrical signals;
- The server’s NIC encodes the electrical signals back into a L2 frame which in turn, is further decapsulated all the way up to L7. Lastly, the IIS server processes the user-data.
Hopefully you can now see how the OSI model …
- Reduces complexity
- Promotes modularity
- Provides scalability
Rafael A. Couto Cabral • LinkedIn Profile
Cisco | F5 | VMware Certified • PRINCE2 Practitioner
Originally posted 2015-01-16 11:30:22.