CCNA | P1: Fundamentals Of Computer Networks | C1: TCP/IP & OSI Models
If you are interested in learning how computers communicate over networks, you may have heard of the terms TCP/IP and OSI. These are two models that describe how different layers of protocols work together to enable data transmission. In this article, we will explain what these models are, how they differ, and why they are important for network engineers and developers.
TCP/IP Model
TCP/IP stands for Transmission Control Protocol/Internet Protocol. It is a four-layer model that was developed by the US Department of Defense in the 1970s for ARPANET the predecessor to Internet to connect different types of computers and networks and to addresses specific communication challenges and relies on standardized protocols. It is a set of rules that define how data is transmitted and received over the Internet. The four layers from Top to Bottom are:
- Application layer: This is where the user interacts with the network applications, such as web browsers, email clients, or FTP clients. The application layer protocols define the rules and formats for exchanging data between applications, such as HTTP, SMTP, or FTP.
- Transport layer: This is where the data is segmented, sequenced, and acknowledged by the sender and receiver. The transport layer protocols ensure reliable and efficient data delivery, such as TCP or UDP.
- Internet layer: This is where the data is routed across different networks using logical addresses, such as IP addresses. The internet layer protocols handle the addressing and routing of packets, such as IP, ICMP, or ARP.
- Network access layer: This is where the data is converted into electrical signals and transmitted over physical media, such as cables or wireless signals. The network access layer protocols deal with the hardware and physical aspects of the network, such as Ethernet, Wi-Fi, or Bluetooth.
There are some TCP/IP models which are described in 5 layers' where the Network Access Layer is divided in to 2 Layers.
1. Data-Link Layer: It compromises of Logical Components including MAC Address.
2. Physical Layer: It compromises of the Physical aspects of a network connection, wiz:
- Medium of communication along appropriate connectors
- Twisted Copper Pair
- Wi-Fi
- Fiber Optic Cables
Note: The 5-layer model is only referred when comparing TCP/IP models with OSI model, in practicality Only the 4 Layer Model is Used.
OSI Model
OSI stands for Open Systems Interconnection. It is a seven-layer model that was developed by the International Organization for Standardization (ISO) in the 1980s to provide a common framework for network communication. The seven layers from top to bottom are:
- Application layer: This is similar to the application layer in TCP/IP, but it also includes some functions that are performed by lower layers in TCP/IP, such as encryption, compression, or authentication.
- Presentation layer: This is where the data is formatted, translated, and encoded for different applications and systems. The presentation layer protocols handle the syntax and semantics of the data, such as ASCII, JPEG, or SSL.
- Session layer: This is where the communication sessions are established, maintained, and terminated between applications. The session layer protocols manage the synchronization and coordination of the data exchange, such as RPC, NFS, or SQL.
- Transport layer: This is similar to the transport layer in TCP/IP, but it also provides some services that are performed by higher layers in TCP/IP, such as flow control, error recovery, or multiplexing.
- Network layer: This is similar to the internet layer in TCP/IP, but it also provides some functions that are performed by lower layers in TCP/IP, such as congestion control, fragmentation, or quality of service.
- Data link layer: This is similar to the network access layer in TCP/IP, but it is divided into two sublayers: logical link control (LLC) and media access control (MAC). The LLC sublayer provides error detection and correction, while the MAC sublayer provides access to the shared media.
- Physical layer: This is where the data is converted into bits and transmitted over physical media. The physical layer protocols define the electrical and mechanical characteristics of the network, such as voltage levels, connectors, or cables.
I am sure it seems a bit overwhelming to remember these 7 layers in sequence, worry not over the years i picked a quite simple mnemonics which I have shared below:
All People Seem To Need Data Processing
All stands for Application
People stands for Presentation
Seem stands for Session
To stands for Transport
Need stands for Network
Data stands for Data-Link
Processing Stands for Physical
The main differences between TCP/IP and OSI are:
TCP/IP Model | OSI Model |
---|---|
Practical model based on specific protocols | Theoretical model based on abstract concepts |
Consists of four layers: application, transport, internet, and network access | Consists of seven layers: application, presentation, session, transport, network, data link, and physical |
More widely used and implemented than OSI | Less widely used and implemented than TCP/IP |
Simpler and more flexible than OSI | More comprehensive and detailed than TCP/IP |
TCP/IP Model:
-
The application layer handles the creation and formatting of the email message using protocols such as SMTP (Simple Mail Transfer Protocol) or IMAP (Internet Message Access Protocol).
-
The transport layer divides the message into smaller packets and adds headers with information such as source and destination ports using protocols such as TCP (Transmission Control Protocol) or UDP (User Datagram Protocol).
-
The internet layer adds headers with information such as source and destination IP addresses using protocols such as IP (Internet Protocol) or ICMP (Internet Control Message Protocol).
-
The network access layer converts the packets into bits and sends them over the physical medium using protocols such as Ethernet or Wi-Fi.
-
The process is reversed at the receiving end.
OSI Model:
-
The application layer handles the creation and formatting of the email message using protocols such as SMTP or IMAP.
-
The presentation layer converts the message into a common format that can be understood by different systems using protocols such as ASCII or MIME (Multipurpose Internet Mail Extensions).
-
The session layer establishes, maintains, and terminates the connection between the sender and receiver using protocols such as RPC (Remote Procedure Call) or SSL (Secure Sockets Layer).
-
The transport layer divides the message into smaller packets and adds headers with information such as source and destination ports using protocols such as TCP or UDP.
-
The network layer adds headers with information such as source and destination IP addresses using protocols such as IP or ICMP.
-
The data link layer adds headers with information such as MAC (Media Access Control) addresses using protocols such as Ethernet or Wi-Fi.
-
The physical layer converts the packets into bits and sends them over the physical medium using protocols such as electrical signals or radio waves.
-
The process is reversed at the receiving end.
Conclusion
As you can see, both models follow a similar logic of encapsulating data with headers at each layer and decapsulating it at the receiving end. However, the OSI model has more layers and more details than the TCP/IP model.
The TCP/IP and OSI models are useful tools for understanding how network communication works. They help us to learn about the different protocols and functions involved in sending and receiving data over networks. They also help us to troubleshoot problems and design better systems.
We hope you enjoyed this article and learned something new about TCP/IP and OSI models. If you have any questions or feedback, please feel free to reach out on below link.