geeksforgeeks.org/routing-tables-in-computer-network/

截屏2022-10-03 上午11.30.53.png

We have 4 hosts: juliet, romeo, ophelia, hamlet and othello, and 3 routers: router-1 , router-2 andn router-3. We have 4 network segments: 4 physical points of connection between network interfaces. (color - network segments). We have labelled each interface, i.e. each attachment to its network segment with its IP address. We have labeled the network address with bold text.

Each interface is with a netmask of 255.255.255.0

Red: network address is 10.10.0.0/24 so each network interface attached to it should have IP address like 10.10.0.x(free), where ‘/24’ means.

Similar with all other three network segment.

4.1 Exercises with IP address and subnet mask in a single segment network

Untitled

In a previous experiment, we saw that when a host needs to send an IP packet, it uses ARP to resolve the destination IP address to a MAC address. We observed three possible outcomes of this process:

However, these three scenarios only occur if the host first checks its routing table, and determines that the route that matches this destination address is a directly connected route.