man what I wouldn't do to get a BSCN book that treats the reader like a total idiot... instead of the two i've gone through that assumes the reader understands the 70% of the explanation that is omitted.
alright this is from the cisco press book: "Building Scalable Cisco Networks"
pg.80 top
<< Selecting routes from route summaries - If more than one entry in the routing tale matches a particular destination, the longest prefix match in the routing table is used. Seeral roures might match one destination, but the logest matching prefix is used.
For example, if a routing tables has the paths shown in Figure 2-8, packets addressed to destination 172.16.5.99 would be routed through the 172.16.5.0/24 path because that address has the longest match with the destination address."
Figure 2-8 Routers will use the longest match when selecting a route
172.16.5.33 - /32 - Host
172.16.5.32 - /27 - Subnet
172.16.5.0 - /24 - Network
172.16.0.0 - /16 - Block of networks
0.0.0.0 - /0 - Default
>>
what the hell is going on here... I'm lost... okay I get that the route that has the longest prefix is chosen... does anyone care to tell me why?
more importantly though, how does this example work? wouldn't the longest subnet be the subnet that the host belongs to... umm what would it be... errr 172.16.5.96/27?
I'm lost as to why 172.16.5.0/24 is used when you can use the subnet that the host belongs to... that subnet has 3 extra prefix bits than what they've used right now.