OSI (Open System Interface)
It defines how data communication happens, the protocols involved.
PHYSICAL LAYER
* First layer of OSI model.
* Represents the bits.
* It deals with :-
Transmission media for data communication.
Electrical and mechanical functions of interface or ports or media.
Procedures and functions of transmission media.
Examples:
Hardware: Network adapter, Repeater, Network hub, Modem, Fiber Media Converter.
Protocols: DSL, ISDN all the physical topologies etc..
DATA LINK LAYER
* Second Layer
* Converts bits(0s and 1s) into Frames.
* Data link layer moves the frames from one hop to the other(from one network to the other).
* Physical addressing.
* Flow control.
* Error detection and error notification.
To detect errors, it uses a technology called CRC(Cyclic Redundancy Check).
* FCS (Frame Check Sequence)
* Access control >> The sender takes control of the reciever. Sender decides when to send the data.
* LLC and MAC work at this layer.
MAC Layer : It does the framing, physical addressing, line discipline, Error notification and error detection.
LLC Layer : Sequencing of bits and identifying the upper layer protocol.
Protocols : ARP, ARCnet, ATM, IEEE 802.2 (provides LLC functions to IEEE 802 MAC layers), IEEE 802.11 wireless LAN, Network Discovery, PPP, Frame Relay, Token Ring.
NETWORK LAYER
* Frames are converted to packets.
* Encapsulation of IP address takes place.
* Logical addressing.
Note: Addressing is done at the data link layer as well, but those addresses refer to local physical devices. In contrast, logical addresses are independent of particular hardware
and must be unique across an entire internetwork.
* Routing :- Determines the route through which the data has to be travelled.
Protocols: ipv4, v6, ICMP, IPsec, RIP, DDP.
TRANSPORT LAYER
* Packets are converted into segments.
* Sequencing : For each segment a sequence number is given. Each segment is put into correct sequence.
* Port addressing. Port service is chosen by Transport layer.
* Flow control: To avoid overloading, it controls the flow of data between 2 devices.
* Controls the flow of data.
* Error Control: Data is re-send from the source in case of error detection.
Protocols: TCP, UDP
SESSION LAYER
* Session is referred to as a network dialog. This is the layer which controls the network dialog between source and destination.
* Services like http, https, ftp etc are identified in this layer.
* It establishes, manages and terminates a session. This 3 step process is called dialog control.
* It creates synchronisation points/checkpoints which helps in continous flow of data in case a session is cut during communication.
* Mode of communication. ie 1.Duplex 2.Full Duplex 3. Semi-duplex.
Untill now the data is in the form of bits (os and 1s)
PRESENTATION LAYER
* Acts as a translator.
* Identifies the format of data.
* Encryption and Decryption is done in the layer.
* Compression and decompression.
APPLICATION LAYER
* It is the interface between user and application.
* E-mail comes in the application layer.
* File management, File transfer, file access, AD services are all in apllication layer.
Process of Encapsulation
If a data has to be transmitted it must be packaged by a process called encapsulation. As data moves down through each layer, each layer adds it's own header to the data before passing it to the next layer.
Below diagram will give you a better understanding.