What is OSI Model?
- The open systems interconnection (OSI) model is a conceptual model created by the International Organization for Standardization(ISO). The OSI provides a standard for different computer systems to be able to communicate with each other.
The model is called the ISO OSI Reference Model because it deals with connecting open system--that is, systems that are open for communication with other systems. We will just call it the OSI model for short.
The modern Internet is not strictly based on OSI, but on the simpler TCP/IP model. However, the OSI 7-layer model is still widely used, as it helps visualize and communicate how networks operate, and helps isolate and troubleshoot networking problems.
OSI consists of seven layers, and each layer performs a particular network function. Each layer of the OSI Model handles a specific job and communicates with the layers above and below itself.
Let's discuss each of the following layers of the OSI model:
- Physical Layer.
- Data Link Layer.
- Network Layer.
- Transport Layer.
- Session Layer.
- Presentation Layer.
- Application Layer.
I’ll describe OSI layers “top down” from the application layer that directly serves the end user, down to the physical layer.
How to remember all the names of the layers?
- Please | Physical Layer
- Do | Data Link Layer
- Not | Network Layer
- Tell (the) | Transport Layer
- Secret | Session Layer
- Password (to) | Presentation Layer
- Anyone | Application Layer
Application Layer :
- This is the only layer that directly interacts with data from the user. Software applications like web browsers and email clients rely on the application layer to initiate communications. Applications include software programs that are installed on the operating system, like Internet browsers (for example, Firefox) or word processing programs (for example, Microsoft Word).
- But it should be made clear that client software applications are not part of the application layer; rather the application layer is responsible for the protocols and data manipulation that the software relies on to present meaningful data to the user.
- Everything at this layer is application-specific. This layer provides application services for file transfers, email, and other network software services. Telnet and FTP are applications that exist entirely at the application level.
The various protocols used in this layer are:
- DNS (Domain Name System),
- SMTP (Simple Mail Transfer Protocol),
- FTP (File Transfer Protocol),
- POP (Post Office Protocol),
- HTTP (HyperText Transfer Protocol), etc.
Presentation Layer :
- This layer works to transform data into the form that the application layer can accept. For example, the presentation layer could convert a text computer file that is EBCDIC-coded into an ASCII-coded file.
- Since different computer systems use different encoding systems so the presentation layer must translate the data into a computer-dependent format.
- The presentation layer deals with the encryption and decryption of the data so that the data can be transmitted securely.
- The presentation layer also deals with the compression and expansion of the information.
- If the devices are communicating over an encrypted connection, this layer is responsible for adding the encryption on the sender’s end as well as decoding the encryption on the receiver's end so that it can present the application layer with unencrypted, readable data.
- The presentation layer is also responsible for compressing data it receives from the application layer before delivering it to layer 5(Session Layer). This helps improve the speed and efficiency of communication by minimizing the amount of data that will be transferred.
There are three data formatting methods to be aware of:
- American Standard Code for Information Interchange (ASCII)
- Extended Binary-Coded Decimal Interchange Code (EBDCIC)
- Unicode
The various protocols used in this layer are:
- AFP (Apple Filing Protocol),
- ICA (Independent Computing Architecture),
- Citrix system core protocol,
- LPP (Lightweight Presentation Protocol),
- NCP (NetWare Core Protocol),
- NDR (Network Data Representation),
- Tox protocol, etc.
Session Layer :
- This is the layer responsible for opening and closing communication between the two devices. The time between when the communication is opened and closed is known as the session. The session layer ensures that the session stays open long enough to transfer all the data being exchanged, and then promptly closes the session in order to avoid wasting resources.
- The session layer also synchronizes data transfer with checkpoints. For example, if a 100 megabyte file is being transferred, the session layer could set a checkpoint every 5 megabytes. In the case of a disconnect or a crash after 52 megabytes have been transferred, the session could be resumed from the last checkpoint, meaning only 50 more megabytes of data need to be transferred. Without the checkpoints, the entire transfer would have to begin again from scratch.
- The main aim is to establish, manage, and terminate the connection between applications
- An example of a session layer protocol is the ISO 8327 protocol. This protocol can be used to recover a lost connection. This session layer protocol also may close and reopen connections that have not been used for a long period of time.
The various protocols used in this layer are :
- PAP (Password Authentication Protocol)
- PPTP (Point-to-Point Tunneling Protocol)
- RPC (Remote Procedure Call Protocol)
- RTCP (Real-time Transport Control Protocol), etc.
Transport Layer :
- It is responsible for end-to-end communication between the two devices. This includes taking data from the session layer and breaking it up into chunks called segments before sending it to network layer.
- It is responsible for the process to process delivery of data. The main aim of the transport layer is to maintain the order so that the data must be received in the same sequence as it was sent by the sender.
- The transport layer is also responsible for flow control and error control. Flow control determines an optimal speed of transmission to ensure that a sender with a fast connection doesn’t overwhelm a receiver with a slow connection.
- The transport layer performs error control on the receiving end by ensuring that the data received is complete, and requesting a retransmission if it isn’t.
- Transmission Control Protocol (TCP) and User Datagram Protocol (UDP) are two of the most well-known protocols in Layer 4.
- One of the major tasks of the transport layer is to add the port addressing (addition of a port number to the header of the data). The port number is added so that the data can be sent at the respective process only.
- The transport layer on the receiver's end reassembles the segments to form the actual data.
Network Layer :
It provides switching and routing technologies. It also uses network layer protocols, like routing protocols, to create logical paths, known as virtual circuits, that transmit data from node to node at an assigned destination and source IP address.
- Routing and packet forwarding are functions of the network layer as well as addressing, internetworking, error control, congestion control, and packet sequencing.
- Network Layer is where we send information "between" and "across" networks through the use of routers. Instead of just node-to-node communication, we can now do network-to-network communication.
- Routers are the workhorse of this layer we couldn’t have Layer 3 without routers. They move data packets across multiple networks.
- Not only do they connect to Internet Service Providers (ISPs) to provide access to the Internet, they also keep track of what’s on its network (remember that switches keep track of all MAC addresses on a network), what other networks it’s connected to, and the different paths for routing data packets across these networks. Routers store all of this addressing and routing information in routing tables.
- The network layer adds the logical address i.e. IP address (Internet Protocol address) if the packet crosses the network boundary. It helps in the proper identification of devices on the network. Hence, the network layer adds the source and destination address to the header of the frame.
- The network layer also finds the best physical path for the data to reach its destination; this is known as routing.
The various protocols used in this layer are :
- IPv4 (Internet Protocol version 4),
- IPv6 (Internet Protocol version 6),
- ICMP (Internet Control Message Protocol),
- IPSEC ( IP Security),
- ARP (Address Resolution Protocol),
- MPLS (Multiprotocol Label Switching), etc.
Data Link Layer :
- It is very similar to the network layer, except the data link layer facilitates data transfer between two devices on the SAME network.
- It is used to transmit the error-free frames from one node to the other. If the two computer nodes are on the same networks, then the data link layer provides a connection between the two nodes. The main work of the data link layer is to convert the data into the form of frames.
- Framing is the technique in which the data is divided into streams of bits (called frames) received from the network layer. Along with the conversion of data into frames, the data link layer adds a header and trailer to the frames. The header (present at the starting of the frame) contains the hardware's physical address of source and destination. The trailer (present at the end of the frame) contains the error detection and correction bits.
- The data link layer also maintains the flow control of data during transmission. Suppose that the rate of data transmission and data absorption varies then there is data loss, so the data link layer maintains the flow control.
- The data link layer adds the error detection and correction bits at the end of the frames in the form of trailers. These bits are used to detect the errors and then retransmit the damaged or lost data to prevent any kind of duplication.
- The physical address is also known as the MAC (media access control) address. The MAC address is a unique address of each computer present on the NIC card.
Each frame contains a frame header, body, and a frame trailer:
- Header: Typically includes MAC addresses for the source and destination nodes.
- Body: Consists of the bits being transmitted.
- Trailer: Includes error detection information.
Physical Layer :
- This layer includes the physical equipment involved in the data transfer, such as the cables and switches. This is also the layer where the data gets converted into a bit stream, which is a string of 1s and 0s. The physical layer of both devices must also agree on a signal convention so that the 1s can be distinguished from the 0s on both devices.
- The physical layer encodes the signals at the sender's end and decodes the signals at the receiver's end. It also defines the type of encoding scheme to be used (how 0's and 1's are to be changed into signals).
- It deals with the type of topology to be used for example ring, mesh, bus, star, hybrid, etc. Network topology is the physical and logical arrangement of nodes and connections in a computer network.
- The physical layer also deals with the direction and type of transmission between two or more devices.
The mode of transmission can be simplex, half-duplex, and full duplex.
- Simplex : communication channel that sends information in only one direction. Example: Keyboard, Monitor etc.
- Half-duplex : communication channel that sends information in both directions, but one at a time. Example: Walki-Talkies etc.
- Full-duplex : communication channel that sends information in both directions on a network at the same time. Example: Telephone etc.
The various protocols used in the physical layer are :
- Digital Subscriber Line.
- Integrated Services Digital Network.
- Ethernet, etc.
Summary of the OSI model:
References:
Thanks For Reading this😊😊 If you like it then Like,Share and Follow me for more such content.✨✨