TCP/IP model: A framework used to visualize how data is organized and transmitted across a network
Transmission Control Protocol (TCP): An internet communication protocol that allows two devices to form a connection and stream data
Open systems interconnection (OSI) model: A standardized concept that describes the seven layers computers use to communicate and send data over the network
Let’s explore the OSI (Open Systems Interconnection) model and compare it to the TCP/IP model through a story, I hope that will make us understand and visualize better.
The OSI Model: A Seven-Story School Building
Imagine a seven-story school building where each floor represents a layer of the OSI model. This school is designed to help students (data) move from one classroom (computer) to another across town (network).
The Seven Floors (OSI Layers)
- Ground Floor – Physical Layer: This is where the school buses (physical connections) pick up and drop off students. It deals with the actual physical transfer of data.
- 1st Floor – Data Link Layer: Here, the hall monitors (switches and network cards) ensure students move in orderly lines and don’t bump into each other.
- 2nd Floor – Network Layer: The school’s GPS system (routers) helps determine the best route for students to reach their destination classroom.
- 3rd Floor – Transport Layer: This is where the attendance office (TCP/UDP) keeps track of all students, ensuring they arrive safely and in the correct order.
- 4th Floor – Session Layer: The school counselor’s office manages student exchanges and keeps track of which students are talking to each other.
- 5th Floor – Presentation Layer: The language lab translates and formats information so students from different backgrounds can understand each other.
- 6th Floor – Application Layer: This is where students interact with their learning applications and software.
The best part is the students has to pass through all this layers. 🙂
The TCP/IP Model: A Simplified Four-Story Building
Now, let’s compare this to the TCP/IP model, which is like a simplified four-story version of the same school:
- Ground Floor – Network Access Layer: Combines the functions of the Physical and Data Link layers from the OSI model.
- 1st Floor – Internet Layer: Similar to the Network layer in the OSI model.
- 2nd Floor – Transport Layer: Equivalent to the Transport layer in the OSI model.
- 3rd Floor – Application Layer: Combines the functions of the Session, Presentation, and Application layers from the OSI model.
As in the comparision we have observed, TCP/IP model is just another manifestation of OSI model. Both are practically doing the same thing but explaining in a different way.
The Story: A Day in the Life of a Data Packet
Let’s follow a data packet named Daisy as she travels through the OSI model school:
- Daisy starts her journey on the 6th floor (Application Layer), where she has created as an email.
- She then goes down to the 5th floor (Presentation Layer), where her message is encrypted for security.
- On the 4th floor (Session Layer), Daisy gets a special stamp showing she’s part of an email conversation.
- At the 3rd floor (Transport Layer), Daisy’s email is divided into smaller pieces, each with a sequence number.
- The 2nd floor (Network Layer) determines the best route for Daisy’s email to reach her destination.
- On the 1st floor (Data Link Layer), Dais’s email gets packed into frames with error-checking information.
- Finally, at the ground floor (Physical Layer), Daisy’s email is converted into electrical signals and sent over the network.
At the receiving end, Daisy’s email travels up through all seven floors, being reassembled and processed at each level until she reaches the Application Layer as a complete email.
Comparison with TCP/IP
In the TCP/IP model, Daisy’s journey would be similar but condensed:
- She’d start on the 3rd floor (Application Layer), covering the functions of the top three OSI layers.
- The 2nd floor (Transport Layer) would handle her segmentation and sequencing.
- The 1st floor (Internet Layer) would determine her routing.
- Finally, the ground floor (Network Access Layer) would handle both her framing and physical transmission.
This story illustrates how the OSI model provides a more detailed breakdown of network functions, while the TCP/IP model offers a more streamlined, practical approach that’s widely used in real-world networking. By visualizing these models as school buildings, I hope any one can better understand the complex process of data transmission and how different layers work together to ensure information reaches its destination correctly and efficiently.
Here are some reallife examples of 7 OSI layers :
7. Application Layer
- Web browsers (Chrome, Firefox) using HTTP/HTTPS to access websites
- Email clients (Outlook, Gmail) using SMTP for sending emails
- File transfer applications using FTP
- Skype and other messaging apps
6. Presentation Layer
- File format conversion (e.g., JPEG to PNG)
- Data encryption and decryption for secure communications
- Character encoding (ASCII, Unicode)
- Media format conversion (e.g., MIDI for audio)
5. Session Layer
- Authentication and authorization in login sessions
- Setting up and managing communication sessions between applications
- Synchronizing data transfer with checkpoints
4. Transport Layer
- TCP (Transmission Control Protocol) for reliable data transfer
- UDP (User Datagram Protocol) for faster, less reliable transfer
- Port numbers to identify specific applications (e.g., HTTP uses port 80)
3. Network Layer
- IP (Internet Protocol) addressing and routing
- Routers operating at this layer to direct data packets
- ICMP (Internet Control Message Protocol) for network diagnostics
2. Data Link Layer
- Ethernet protocol in local area networks (LANs)
- MAC (Media Access Control) addressing
- Network switches operating at this layer
1. Physical Layer
- Network cables (e.g., Ethernet, fiber optic)
- Wi-Fi radio signals
- RJ45 connectors
- Network interface cards (NICs)
These examples demonstrate how the OSI model layers are present in our everyday use of technology and networking. From the physical connections we use to access the internet, up to the applications we interact with, each layer plays a crucial role in enabling seamless communication between devices and networks.