The Network Layer determines the path and the logical IP address.
Important: A Network layer is not required if two communicating devices lie on the same network. However, when the two devices are connected on a different network, a network layer is essential for providing source to destination delivery of packets.
The characteristics of Layer 3 are:
- When the packet is intended for a device outside the network , other addressing structures are required to identify the source and destination.
- The Network layer adds a header that includes the logical address (IP address) of the source and destination.
- Routers operate at this layer.
- The data unit at this layer is known as packet.
- Internet protocol (IP)is responsible for routing , directing datagrams from one network to another.
Let us study this example of a logical IP address in a network layer.
The typical process for a netwo rk layer is to break large datagrams , into smaller packets and the host receiving the packet will have to reassemble the fragmented datagram. At time the data may be larger than MTU. IP identifies each host with a 32-bit IP address.
IP addresses are written as decimal number, separated by four dots. The numbers will be between 0 and 255. For Ex:126.96.36.199
Tip: even though IP packets are addressed using IP addresses must be used to actually transport data from one host to another.
- The Address Resolution Protocol (ARP)is used to map the IP address to its MAC address.
IP Routing Basics:
Routing is the process of identifying the best reachable path between source and destination.
Routers are used to connect and communicate between two or more different networks and between different geographical locations.
Every router in a network will maintain a routing table to the destination either through static or Dynamic routing.
- Static Routing: This is a simple from of routing. But it is a manual process for configuration of the path to the destination in a router. This is not a routing protocol.
- Dynamic Routing: This is a routing protocol in which the router identifies the best path to the destination. This protocol also communicates information about network destination to all other routers.
- Routing Table: A routing table is a list of known network and destination network learned though the routing process. The routing table provides detailed information about the interface through which it has to forward the Metric (distance) to the destination. Every protocol has a different method of calculation metrics; the best metric is placed in the routing table. Every router maintains a routing table.