Unit 4 Chapter 5 Network Layer
Unit 4 Chapter 5 Network Layer
Layer
The network layer is crucial for delivering data packets from a source to a
destination across multiple networks, operating at Layer 3 of the OSI Model. Key
aspects include store-and-forward packet switching, where routers store and
forward packets, and the debate between connection-oriented and
connectionless services. The Internet favors a connectionless model with IP,
while connection-oriented services like MPLS support Quality of Service (QoS).
Routing algorithms manage packet paths, balancing fairness and efficiency.
The primary function of the network layer is routing packets from source to destination. Routing
involves selecting paths, while forwarding transmits packets based on routing tables. Desirable
routing algorithm properties include robustness, stability, fairness, and efficiency. Algorithms are
classified into nonadaptive (static) and adaptive (dynamic). The optimality principle states that if a
router is on the optimal path between two points, then the path from that router to the destination
is also optimal.
Addressing and Routing Challenges
The count-to-infinity problem occurs in distance vector routing when routers react quickly to good news (shorter paths) but slowly to
bad news (failed links or routers). It happens because routers rely on neighbor updates to estimate paths, which can lead to incorrect
routing loops.
IPv4 uses 32-bit addresses, assigning each network interface its own IP address. IPv4 addresses are hierarchical, divided into a network
portion (prefix) and a host portion. Prefixes reduce router table sizes, but the hierarchy can be wasteful of addresses. Subnetting divides a
larger block into smaller subnets for internal use, optimizing address usage. Classful addressing, with classes A, B, C, D, and E, has issues
such as address space wastage and routing table explosion.
Modern Solutions: CIDR, NAT, and IPv6
1. CIDR (Classless Inter-Domain Routing) solves routing table explosion by using route aggregation to combine smaller prefixes into larger
ones (supernets).
2. NAT (Network Address Translation) allows multiple devices to share a single public IP by mapping private IP addresses to a public one,
addressing IP address shortage.
3. IPv6 uses 128-bit addresses, ensuring an abundant supply of addresses, and includes features like simplified headers and enhanced
security.
Internet Control Protocols like ICMP, ARP, and DHCP assist in network operations. ICMP reports errors and tests network connectivity. ARP
maps IP addresses to MAC addresses. DHCP manages automatic IP address assignment to network devices. These protocols are essential
for efficient and reliable network communication.