4A0-102 practice question 10 of 25

A router in AS 65100 receives two BGP routes. The first route is for 138.1.1.0/24 with an AS Path of 65200 65300, Local Preference of 100, MED of…

Full set: 152 questions
A router in AS 65100 receives two BGP routes. The first route is for 138.1.1.0/24 with an AS Path of 65200 65300, Local Preference of 100, MED of 100, and router ID 10.10.10.10. The second route is for 138.1.0.0/16 with an AS Path of 65500 65300, Local Preference of 150, MED of 100, and router ID 10.1.1.1. Assuming all other attributes are equal, which route would be used to forward an IP packet with destination IP address 138.1.1.1?
Answer options
A: The first BGP route. Correct answer
B: The second BGP route.
C: Both routes are used.
D: It is impossible to determine without the value of the origin code for both routes.
Correct Answer:
A. The first BGP route.
Explanation

The fundamental principle for IP packet forwarding is the longest prefix match rule. The destination IP address 138.1.1.1 matches both advertised prefixes: 138.1.1.0/24 and 138.1.0.0/16. The router's forwarding plane will always select the route with the most specific prefix length. In this case, /24 is more specific than /16. Therefore, the first BGP route (138.1.1.0/24) is installed in the forwarding table and used to forward the packet. The BGP best path selection attributes (Local Preference, MED, etc.) are only used by the control plane to decide between multiple paths to the exact same prefix, not for choosing between different prefixes during the forwarding lookup.

Why Incorrect

B. The second BGP route is incorrect because its prefix (/16) is less specific than the first route's prefix (/24), and the longest match rule takes precedence.
C. Both routes are not used. Standard IP unicast forwarding selects a single best path from the forwarding table for a given destination.
D. The origin code, like other BGP attributes, is irrelevant here because the forwarding decision is made based on the longest prefix match, not the BGP path selection criteria for different prefixes.

References

1. Nokia 7750 SR OS R19.10.R1 Router Configuration Guide, Chapter: IP Router Configuration, Section: Route Tables. The guide states, "When a packet is received, the destination IP address is used as a key to find the best matching IP prefix in the FIB. The longest prefix match is always the preferred one." This confirms the primary rule for the forwarding decision.

2. Nokia 7750 SR OS R19.10.R1 Router Configuration Guide, Chapter: BGP, Section: BGP Best Path Selection. This section details the BGP decision process, which is applied "When BGP receives multiple paths to the same destination". This clarifies that attributes like Local Preference are only compared for routes to the identical prefix, which is not the case here.

3. RFC 1812, "Requirements for IP Version 4 Routers", Section 5.2.4.3, "Forwarding Algorithm". This foundational IETF standard specifies that for any given IP datagram, a router must search its routing table for the route that has the longest possible network prefix that matches the destination address.

Scroll to Top