Soru

Zorluk: ZorRouting Concepts and Dynamic Routing Protocols

An enterprise edge router receives an IP packet destined for host address 172.16.42.100172.16.42.100. The router's active routing table contains four candidate routes:

Protocol SourceDestination SubnetAdministrative DistanceMetricNext Hop
Static172.16.0.0/16172.16.0.0/1610Null0
eBGP172.16.40.0/21172.16.40.0/2120100192.168.1.1192.168.1.1
OSPF172.16.42.0/24172.16.42.0/241102010.0.0.210.0.0.2
RIPv2172.16.42.96/28172.16.42.96/28120210.0.0.610.0.0.6

Which route will the router select to forward the packet, and why?

  1. The RIPv2 route (172.16.42.96/28172.16.42.96/28), because Longest Prefix Match takes precedence over Administrative Distance.Cevap
  2. B
    The Static route (172.16.0.0/16172.16.0.0/16), because static routes have the lowest Administrative Distance.
  3. C
    The eBGP route (172.16.40.0/21172.16.40.0/21), because exterior gateway protocols are prioritized over interior gateway protocols.
  4. D
    The OSPF route (172.16.42.0/24172.16.42.0/24), because it offers the optimal balance between prefix specificity and Administrative Distance.

Cevap

The router will select the RIPv2 route (172.16.42.96/28172.16.42.96/28) because Longest Prefix Match (LPM) is the absolute first criterion used in IP routing decisions, taking precedence over Administrative Distance and metric.
When a router receives a packet, it evaluates all matching routing table entries using the Longest Prefix Match (LPM) rule first. Because 172.16.42.96/28172.16.42.96/28 has the longest subnet mask (/28 = 28 matching bits) among all matching candidate routes, it is chosen immediately. Administrative Distance (AD) and metrics are only evaluated to select a winner when two or more routes advertise identical destination prefix lengths.

Adım Adım Çözüm

1
Determine which routing table entries match the target IP address (172.16.42.100172.16.42.100).
All four entries match: 172.16.0.0/16172.16.0.0/16 (range 172.16.0.0172.16.255.255172.16.0.0 - 172.16.255.255), 172.16.40.0/21172.16.40.0/21 (range 172.16.40.0172.16.47.255172.16.40.0 - 172.16.47.255), 172.16.42.0/24172.16.42.0/24 (range 172.16.42.0172.16.42.255172.16.42.0 - 172.16.42.255), and 172.16.42.96/28172.16.42.96/28 (range 172.16.42.96172.16.42.111172.16.42.96 - 172.16.42.111).
The router must filter candidate routes to only those subnets that encompass the destination address.
2
Compare the prefix lengths (subnet masks) of all matching candidate routes.
Prefix lengths are /16, /21, /24, and /28. The longest prefix match is /28.
In IP routing, the most specific route (highest prefix length) is always selected before Administrative Distance or metric are evaluated.
3
Identify the protocol associated with the longest prefix match (/28).
The /28 route corresponds to the RIPv2 learned entry via next-hop 10.0.0.610.0.0.6.
Administrative Distance (120 vs 1 vs 20 vs 110) is ignored because the prefix lengths are not equal.

Anahtar Kavram

Longest Prefix Match (LPM) Rule
Bu soruyu puanla