The actual communication between networked devices takes place on layer 2. However, Layer 3 is required to route this traffic between different networks. The LAN network and the Internet are diffferent IP networks. This is layer 3. Thet IP happens in Layer 3. IP addressing is required when someone need to move between two separate IP networks. The gateway address is an interface on the router that "knows" about both networks and must be on the same network as the host making the request.
If the router doesn't know about the Internet address a user give it then it will send it to it's gateway which is another router. Then it will send it to it's gateway and so forth until the destination network is reached.
Each step along the way requires a new set of ARPing. The ARP tables on most Cisco routers are retained for 4 hours by default so the ARP requests don't happen all the time, the MAC address are remembered. Also, the ARP is a broadcast protocol. Broadcasts don't cross routers by default. Routers can't ARP for Internet addresses because the Internet is a routed network. LANs are typically switched networks and broadcasts do traverse network switches. The Internet routers have tables of routes so they use the logic in their programming to decide which interface would be the best route to send traffic. Once the route is established between you and the destinations, the routers along the way remember the route and keep it in their routing tables. These are dynamic routes and they are retained for a preset time to live period. Of course some of the top level routers have all static routes but they are known by routers on each end.
0 comments:
Post a Comment