Introduction
The Data Link Layer (DLL) is the second layer of the OSI model, responsible for node-to-node data transfer. It takes packets from the Network Layer and encapsulates them into frames for transmission over the physical link.
Layer 7
Layer 6
Layer 5
Layer 4
Layer 3
Layer 2
Layer 1
Primary Functions
1. Framing
Divides the stream of bits from the network layer into manageable data units called frames. Each frame contains a header, payload, and trailer.
2. Physical Addressing (MAC Addressing)
Adds physical addresses (MAC addresses) to the frame header to identify sender and receiver on the local network. MAC addresses are 48-bit hardware addresses burned into NICs.
3. Error Control
Detects and sometimes corrects errors that occur during transmission. Uses techniques like CRC (Cyclic Redundancy Check), Checksum, and ARQ (Automatic Repeat Request).
4. Flow Control
Regulates data transmission rate between sender and receiver to prevent buffer overflow. Techniques include Stop-and-Wait and Sliding Window protocols.
5. Access Control
Determines which device has control over the link at any given time when multiple devices share the same link (Multi-access protocols).
6. Synchronization
Ensures sender and receiver are synchronized regarding bit timing and frame boundaries.
Sublayers of Data Link Layer
• Handles error control & flow control
• Provides interface to Network Layer
• Supports multiple network protocols
• Controls physical media access
• MAC addressing & framing
• CSMA/CD, Token Passing protocols