欢迎您访问 最编程 本站为您分享编程语言代码,编程技术文章!
您现在的位置是: 首页

[Notes] Computer Network - Layers and Protocols-3. Network Layer

最编程 2024-10-06 07:25:11
...

The Network Layer is responsible for routing packets across multiple interconnected networks. It determines the best path for data to travel from the source to the destination. It also handles addressing and packet forwarding.

Responsibilities:

  • Logical Addressing: Assigns IP addresses to devices. An IP address is a logical identifier (e.g., 192.168.1.1).
  • Routing: Determines the best path for data to travel between networks. Routers operate at this layer.
  • Packet Forwarding: Forwards packets from one network to another, ensuring they reach the correct destination.
  • Fragmentation and Reassembly: If a packet is too large for a network, the Network Layer breaks it into smaller packets (fragments) and reassembles them at the destination.

Key Protocols:

  • IP (Internet Protocol): The fundamental protocol for sending data across multiple networks. It handles addressing and routing.
    • IPv4: The most widely used version of IP (192.168.1.1 format).
    • IPv6: The newer version of IP designed to overcome IPv4 address exhaustion (2001:0db8:85a3::8a2e:0370:7334 format).
  • ICMP (Internet Control Message Protocol): Used for diagnostics and error reporting. For example, the ping command uses ICMP to test connectivity.
  • IGMP (Internet Group Management Protocol): Manages multicast group memberships, which is useful for streaming media to multiple recipients.
  • Routing Protocols: These help routers learn the best routes for forwarding packets.
    • OSPF (Open Shortest Path First): A link-state routing protocol used within larger networks.
    • BGP (Border Gateway Protocol): The protocol that manages routing between autonomous systems (AS) on the Internet — essentially the “glue” of the Internet.
    • RIP (Routing Information Protocol): An older distance-vector routing protocol.