An administrator inspects the IPv4 routing table on a Cisco router and observes the following partial output:
text
Codes: C - connected, S - static, D - EIGRP, O - OSPF, B - BGP
Gateway of last resort is not set
10.0.0.0/8 is variably subnetted, 4 subnets, 4 masks
O 10.200.0.0/16 [110/50] via 172.16.1.1, 00:24:12, GigabitEthernet0/1
D 10.200.64.0/18 [90/2172416] via 172.16.2.1, 02:15:04, GigabitEthernet0/2
S 10.200.64.0/24 [120/0] via 172.16.3.1, GigabitEthernet0/3
B 10.200.64.0/20 [20/100] via 172.16.4.1, 05:10:20, GigabitEthernet0/4
Which two statements accurately describe how the router will forward packets based on these routing table components? (Select two.)
- Packets destined for 10.200.64.50 are forwarded out interface GigabitEthernet0/3 because the /24 prefix length represents the longest prefix match.Cevap
- Packets destined for 10.200.70.15 are forwarded via next-hop 172.16.4.1 out interface GigabitEthernet0/4.Cevap
- CPackets destined for 10.200.64.50 are forwarded out interface GigabitEthernet0/2 because EIGRP has a lower administrative distance (90) than the static route (120).
- DPackets destined for 10.200.70.15 are forwarded via next-hop 172.16.2.1 because the /18 route has a lower metric than the BGP route.
Cevap
Packets destined for 10.200.64.50 are forwarded out GigabitEthernet0/3 due to the longest prefix match (/24), and packets destined for 10.200.70.15 are forwarded via next-hop 172.16.4.1 out GigabitEthernet0/4 because /20 is the most specific matching prefix.
A Cisco router forwards packets by comparing the destination IP address against the routing table using the Longest Prefix Match rule. For 10.200.64.50, the /24 entry offers the highest mask length among all matching routes, directing traffic out GigabitEthernet0/3. For 10.200.70.15, the host IP address falls within the 10.200.64.0/20 range (10.200.64.0 to 10.200.79.255), which is more specific than the /18 or /16 entries and excludes the /24 entry. Therefore, it uses the BGP route via 172.16.4.1.
Adım Adım Çözüm
Anahtar Kavram
Longest Prefix Match Forwarding Logic