Consider the BGP network shown in Figure 11.12. There are three ASs, AS5555, AS6666, and AS7777. Router B1 of AS6666 is running BGP with router A1 of AS5555 and router C1 of AS7777. Routers A2 of AS5555 and C2 of AS7777 are also running eBGP among themselves.
Figure 11.12: A scenario showing a complex BGP network.
In Figure 11.12:
Route 192.168.4.0/24 is not available in the routing table of B1. This is evident with the command:
B1#show ip route 192.168.4.0 % Network not in table
The route for network 192.168.1.0/24 from B1 is not via A1, which is the optimum path, but via C1. Listing 11.31 shows the output of the show ip route 192.168.1.0 command.
Listing 11.31 Output of show ip route 192.168.1.0 Command
B1#show ip route 192.168.1.0 Routing entry for 192.168.1.0/24 Known via "bgp 4755", distance 200, metric 0 Tag 4657, type internal Last update from 10.5.1.1 01:12:49 ago Routing Descriptor Blocks: 10.5.1.1, from 10.3.1.2, 01:12:49 ago Route metric is 0, traffic share count is 1 AS Hops 1
To troubleshoot these problems, the neighbor relationship at B1 is established and checked. Listing 11.32 shows the output of the show ip bgp neighbor command.
Listing 11.32 Output of show ip bgp neighbor Command
B1#show ip bgp neighbor BGP neighbor is 10.2.1.1, remote AS 5555, external link BGP version 4, remote router ID 10.2.1.1 BGP state = Established, up for 05:24:26 Last read 00:00:25, hold time is 180, keepalive interval is 60 seconds Neighbor capabilities: Route refresh: advertised and received(new) Address family IPv4 Unicast: advertised and received Message statistics: InQ depth is 0 OutQ depth is 0 Sent Rcvd Opens: 9 9 Notifications: 0 0 Updates: 259104 259 Keepalives: 7185 7184 Route Refresh: 0 0 Total: 266298 7452 Default minimum time between advertisement runs is 5 seconds For address family: IPv4 Unicast BGP table version 27219, neighbor versions 27219/0 27219/0 Output queue sizes: 0 self, 0 replicated Index 8, Offset 1, Mask 0x1 Route-Reflector Client Member of update-group 3 Default weight 100 Sent Rcvd Prefix activity: —— —— Prefixes Current: 101 28 (Consumes 1344 bytes) Prefixes Total: 133 34 Implicit Withdraw: 23 0 Explicit Withdraw: 9 6 Used as bestpath: n/a 28 Used as multipath: n/a 0 Outbound Inbound Local Policy Denied Prefixes: ———— ———— Suppressed due to dampening: 2 n/a Total: 2 0 Number of NLRIs in the update sent: max 290, min 0 Connections established 9; dropped 8 Last reset 05:24:53, due to User reset Connection state is ESTAB, I/O status: 1, unread input bytes: 0 Local host: 10.2.1.2, Local port: 19455 Foreign host: 10.2.1.1, Foreign port: 179 Enqueued packets for retransmit: 0, input: 0 mis-ordered: 0 (0 bytes) Event Timers (current time is 0x19A67740): Timer Starts Wakeups Next Retrans 4040 0 0x0 TimeWait 0 0 0x0 AckHold 334 179 0x0 SendWnd 0 0 0x0 KeepAlive 0 0 0x0 GiveUp 0 0 0x0 PmtuAger 0 0 0x0 DeadWait 0 0 0x0 iss: 370882673 snduna: 371469486 sndnxt: 371469486 sndwnd: 15007 irs: 1820013194 rcvnxt: 1820020445 rcvwnd: 14997 delrcvwnd: 1387 SRTT: 300 ms, RTTO: 607 ms, RTV: 3 ms, KRTT: 0 ms minRTT: 0 ms, maxRTT: 476 ms, ACK hold: 200 ms Flags: higher precedence, nagle Datagrams (max data segment is 1460 bytes): Rcvd: 4234 (out of order: 0), with data: 334, total data bytes: 7250 Sent: 4413 (retransmit: 0, fastretransmit: 0), with data: 4228, total data bytes : 586812 BGP neighbor is 10.3.1.2, remote AS 7777, external link BGP version 4, remote router ID 10.3.1.2 BGP state = Established, up for 05:24:26 Last read 00:00:25, hold time is 180, keepalive interval is 60 seconds Neighbor capabilities: Route refresh: advertised and received(new) Address family IPv4 Unicast: advertised and received Message statistics: InQ depth is 0 OutQ depth is 0 Sent Rcvd Opens: 9 9 Notifications: 0 0 Updates: 259104 259 Keepalives: 7185 7184 Route Refresh: 0 0 Total: 266298 7452 Default minimum time between advertisement runs is 5 seconds For address family: IPv4 Unicast BGP table version 27219, neighbor versions 27219/0 27219/0 Output queue sizes: 0 self, 0 replicated Index 8, Offset 1, Mask 0x1 Route-Reflector Client Member of update-group 3 Default weight 100 Sent Rcvd Prefix activity: —— —— Prefixes Current: 101 28 (Consumes 1344 bytes) Prefixes Total: 133 34 Implicit Withdraw: 23 0 Explicit Withdraw: 9 6 Used as bestpath: n/a 28 Used as multipath: n/a 0 Outbound Inbound Local Policy Denied Prefixes: ———— ———— Suppressed due to dampening: 2 n/a Total: 2 0 Number of NLRIs in the update sent: max 290, min 0 Connections established 9; dropped 8 Last reset 05:24:53, due to User reset Connection state is ESTAB, I/O status: 1, unread input bytes: 0 Local host: 10.3.1.1, Local port: 19455 Foreign host: 10.3.1.2, Foreign port: 179 Enqueued packets for retransmit: 0, input: 0 mis-ordered: 0 (0 bytes) Event Timers (current time is 0x19A67740): Timer Starts Wakeups Next Retrans 4040 0 0x0 TimeWait 0 0 0x0 AckHold 334 179 0x0 SendWnd 0 0 0x0 KeepAlive 0 0 0x0 GiveUp 0 0 0x0 PmtuAger 0 0 0x0 DeadWait 0 0 0x0 iss: 370882673 snduna: 371469486 sndnxt: 371469486 sndwnd: 15007 irs: 1820013194 rcvnxt: 1820020445 rcvwnd: 14997 delrcvwnd: 1387 SRTT: 300 ms, RTTO: 607 ms, RTV: 3 ms, KRTT: 0 ms minRTT: 0 ms, maxRTT: 476 ms, ACK hold: 200 ms Flags: higher precedence, nagle Datagrams (max data segment is 1460 bytes): Rcvd: 4234 (out of order: 0), with data: 334, total data bytes: 7250 Sent: 4413 (retransmit: 0, fastretransmit: 0), with data: 4228, total data bytes : 586812
In Listing 11.32, the command in bold shows the successful establishment of a neighbor relationship of B1 with both A1 and C1. The neighbor relationship between iBGP neighbors C1 and C2 is checked. Listing 11.33 shows the output of the show ip bgp neighbor 10.4.1.2 command.
Listing 11.33 Output of show ip bgp neighbor 10.4.1.2 Command
C1#show ip bgp neighbor 10.4.1.2 BGP neighbor is 10.4.1.2, remote AS 7777, internal link BGP version 4, remote router ID 10.2.1.1 BGP state = Established, up for 03:24:26 Last read 00:00:25, hold time is 180, keepalive interval is 60 seconds Neighbor capabilities: Route refresh: advertised and received(new) Address family IPv4 Unicast: advertised and received Message statistics: InQ depth is 0 OutQ depth is 0 Sent Rcvd Opens: 9 9 Notifications: 0 0 Updates: 259104 259 Keepalives: 7185 7184 Route Refresh: 0 0 Total: 266298 7452 Default minimum time between advertisement runs is 5 seconds For address family: IPv4 Unicast BGP table version 27219, neighbor versions 27219/0 27219/0 Output queue sizes: 0 self, 0 replicated Index 8, Offset 1, Mask 0x1 Route-Reflector Client Member of update-group 3 Default weight 100 Sent Rcvd Prefix activity: —— —— Prefixes Current: 101 28 (Consumes 1344 bytes) Prefixes Total: 133 34 Implicit Withdraw: 23 0 Explicit Withdraw: 9 6 Used as bestpath: n/a 28 Used as multipath: n/a 0 Outbound Inbound Local Policy Denied Prefixes: ———— ———— Suppressed due to dampening: 2 n/a Total: 2 0 Number of NLRIs in the update sent: max 290, min 0 Connections established 9; dropped 8 Last reset 05:24:53, due to User reset Connection state is ESTAB, I/O status: 1, unread input bytes: 0 Local host: 10.4.1.2, Local port: 19455 Foreign host: 10.4.1.1, Foreign port: 179 Enqueued packets for retransmit: 0, input: 0 mis-ordered: 0 (0 bytes) Event Timers (current time is 0x19A67740): Timer Starts Wakeups Next Retrans 4040 0 0x0 TimeWait 0 0 0x0 AckHold 334 179 0x0 SendWnd 0 0 0x0 KeepAlive 0 0 0x0 GiveUp 0 0 0x0 PmtuAger 0 0 0x0 DeadWait 0 0 0x0 iss: 370882673 snduna: 371469486 sndnxt: 371469486 sndwnd: 15007 irs: 1820013194 rcvnxt: 1820020445 rcvwnd: 14997 delrcvwnd: 1387 SRTT: 300 ms, RTTO: 607 ms, RTV: 3 ms, KRTT: 0 ms minRTT: 0 ms, maxRTT: 476 ms, ACK hold: 200 ms Flags: higher precedence, nagle Datagrams (max data segment is 1460 bytes): Rcvd: 4234 (out of order: 0), with data: 334, total data bytes: 7250 Sent: 4413 (retransmit: 0, fastretransmit: 0), with data: 4228, total data bytes : 586812
In Listing 11.33, the establishment of a neighbor relationship between C1 and C2 is confirmed. At C1, check if network 192.168.4.0/24 is declared at B1. This is performed by using the command:
C1#show ip bgp neighbor 10.3.1.1 advertised-routes | include 192.168.4.0
There is no output for this command confirming that the route is not declared at B1. The presence of any filters or route map in the BGP configuration of C1 needs to be checked. The relevant part of the configuration of C1, obtained by executing the command show running-configuration, is shown in Listing 11.34.
Listing 11.34 Output of show running-configuration Command at C1
router bgp 7777 neighbor 10.3.1.1 remote-as 6666 neighbor 10.3.1.1 distribute-list 8 out neighbor 10.4.1.1 remote-as 7777 ! access-list 8 deny 192.168.4.0 0.0.0.255 access-list 8 permit any
Access list 8 is used to filter outgoing BGP updates from C1 to A1. Network 192.168.4.0/24 is matched by access list 8. As a result, the update of the network is not available from C1.
The update should be received by B1 from AS5555 as well, which is also connected to AS7777 (via the WAN link between A2 and C2). Check any filtering of the outgoing routing updates from A2 to C2. The relevant part of the configuration of C2, obtained by executing the command show running-configuration, is shown in Listing 11.35.
Listing 11.35 Output of show running-configuration Command
router bgp 7777 neighbor 10.5.1.1 remote-as 5555 neighbor 10.5.1.1 distribute-list 9 out neighbor 10.4.1.2 remote-as 7777 ! access-list 9 deny 192.168.4.0 0.0.7.255 access-list 9 permit any
In Listing 11.35, propagation of the update corresponding to network 192.168.4.0/24 is restricted by access list 9.
Modify the route filtering at either C1 or C2—or both—so that the route for network 192.168.4.0/24 is available in the BGP table and in the routing table of B1. Confirm establishment of a neighbor relationship of B1 with A1.
Updates for network 192.168.1.0/24 should be available at B1 from both A1 and C1. Check if any weight has been applied to the updates. The relevant part of the configuration of B1 obtained by running the command show running-config in B1 is shown in Listing 11.36.
Listing 11.36 Output of show running-config Command
router bgp 6666 neighbor 10.2.1.1 remote-as 5555 neighbor 10.2.1.1 route-map A1IN in neighbor 10.3.1.2 remote-as 7777 neighbor 10.3.1.2 route-map C1IN in ! route-map A1IN permit 10 match ip address 10 set weight 100 ! route-map C1IN permit 10 match ip address 10 set weight 200 ! access-list 10 permit any
In Listing 11.36, the weight of all routes from C1 is set to a higher value of 200 than the routes from A1, which are set to 100. As a result, C1 is the preferred path for all routes, which are learned both from A1 and C1. The order can be reversed by suitably modifying the weight attribute.