[c-nsp] iBGP routes preferred over eBGP routes...

Bao Nguyen ngqbao at gmail.com
Thu Feb 6 22:13:18 EST 2014


All,

Any help with this would be really appreciated as I've ran out of things to
try.... To summarize, routes learned via iBGP is selected and use while not
learned from local eBGP, I've even lowered the "local preference" on the
iBGP side.

My understanding is that routes from BDR2 will not advertise to BDR1 if
BDR1 is/has better path. I've made that not true by lowering the
local-preference routes in iBGP from BDR1 to BDR2. Here's my topo:
ISP1 -- BDR1 -- (ibgp) -- BDR2 -- ISP2

I've anonymous the IPs and here's a reference.
2.2.2.2 - BDR1
2.2.2.3 - BDR2
3.3.3.3 - ISP2

BDR2 will not advertise any routes to BDR1. IGP synchronization is
disabled. Showing "Local Policy Denied Prefixes" as "Bestpath from this
peer". However no policies to denied this.
bdr2#show ip bgp neighbors 2.2.2.2
<clip>
  Inbound soft reconfiguration allowed
  NEXT_HOP is always this router
                                 Sent       Rcvd
  Prefix activity:               ----       ----
    Prefixes Current:               1     463440 (Consumes 22440720 bytes)
    Prefixes Total:                 1     465959
    Implicit Withdraw:              0       2197
    Explicit Withdraw:              0        322
    Used as bestpath:             n/a     467514
    Used as multipath:            n/a          0

                                   Outbound    Inbound
  Local Policy Denied Prefixes:    --------    -------
    Bestpath from this peer:         465196        n/a
    Total:                           465196          0
  Number of NLRIs in the update sent: max 1191, min 0

Checking routes advertisement
bdr2#show ip bgp neighbors 2.2.2.2 advertised-routes
BGP table version is 314275501, local router ID is 2.2.2.3
Status codes: s suppressed, d damped, h history, * valid, > best, i -
internal,
              S Stale
Origin codes: i - IGP, e - EGP, ? - incomplete

   Network          Next Hop            Metric LocPrf Weight Path
*> 2.2.2.0    0.0.0.0                  0         32768 i

Here's the configuration from BDR2
bdr2#show running | begin bgp
router bgp 100
 bgp router-id 2.2.2.3
 bgp default local-preference 80
 bgp log-neighbor-changes
 neighbor 2.2.2.2 remote-as 100
 neighbor 3.3.3.3 remote-as 200
 maximum-paths 3
 maximum-paths ibgp 3
 default-metric 100
 !
 address-family ipv4
 neighbor 2.2.2.2 activate
 neighbor 2.2.2.2 next-hop-self
 neighbor 2.2.2.2 soft-reconfiguration inbound

BDR2 will alway pick the path to ISP1 via BDR1, even though the routes from
BDR1 are clearly suboptimical. I've bounced via soft and hard reset of both
iBGP and eBGP. Here's an example output.

bdr2#show ip bgp 66.192.9.77
BGP routing table entry for 66.192.0.0/20, version 313836364
Paths: (2 available, best #2, table Default-IP-Routing-Table)
Multipath: eBGP iBGP
  Not advertised to any peer
  200 4323, (received-only)
    3.3.3.3 from 3.3.3.3 (4.4.4.4)
      Origin IGP, metric 3, localpref 80, valid, external
  300 701 4323, (received & used)
    2.2.2.2 from 2.2.2.2 (5.5.5.5)
      Origin IGP, metric 203030, localpref 60, valid, internal, best

Here's the result from "debug ip bgp update <IP>" then clear the session
with 3.3.3.3

BGP(0): 3.3.3.3 rcvd UPDATE w/ attr: nexthop 3.3.3.3, origin i, metric 3,
path 200 4323 29707
BGP(0): 3.3.3.3 rcvd 66.192.25.0/24 -- DENIED due to:
distribute/prefix-list;

BGP(0): process mpath after bestpath selection comparing bestpath 2.2.2.2
(best_idx: 1) with
    path = 3.3.3.3, path_idx = 0, returned mbest_idx = 255

Thank you for reading!


More information about the cisco-nsp mailing list