next-hop-self command issues.

rakemrakem Member Posts: 800
I have the network shown below configured in dynampis.

bgpnet2.jpg


Routers 1 2 3 are in AS 5100. the dotted lines show the iBGP neighbor relationships. There is an eBGP relationship between router 3 and 6.

Router 6 is advertising the 66.66.66.0 /24 network, here is the BGP config:
router bgp 5600
no synchronization
bgp log-neighbor-changes
network 66.66.66.0 mask 255.255.255.0
neighbor 3.3.3.3 remote-as 5100
neighbor 3.3.3.3 ebgp-multihop 2
neighbor 3.3.3.3 update-source Loopback1
neighbor 5.5.5.5 remote-as 5500
neighbor 5.5.5.5 ebgp-multihop 2
neighbor 5.5.5.5 update-source Loopback1
no auto-summary

now i'm just mucking around a bit here, trying some configs with the next hop self command. There is no IGP running in AS 5100 at all. I know that its not fully meshed but thats not the point for this lab.

this is Router 3 bgp table:
Network Next Hop Metric LocPrf Weight Path
*> 33.33.33.0/24 0.0.0.0 0 32768 i
*> 44.44.44.0/24 6.6.6.6 0 5600 5500 5400 i
*> 55.55.55.0/24 6.6.6.6 0 5600 5500 i
*> 66.66.66.0/24 6.6.6.6 0 0 5600 i

all looks good.

however my issue is with R1. Here is the BGP table:
Network Next Hop Metric LocPrf Weight Path
*>i22.22.22.0/24 2.2.2.2 0 100 0 i
*>i33.33.33.0/24 3.3.3.3 0 100 0 i
* i44.44.44.0/24 6.6.6.6 0 100 0 5600 5500 5400 i
* i55.55.55.0/24 6.6.6.6 0 100 0 5600 5500 i
* i66.66.66.0/24 6.6.6.6 0 100 0 5600 i

it has valid routes to the 66.66.66.0 network but they are not marked as best because it has no route to the 6.6.6.6 next hop address.

I thought i could fix this by using the next-hop-self command on R3. As shown here:
router bgp 5100

no synchronization
bgp log-neighbor-changes
network 33.33.33.0 mask 255.255.255.0
neighbor 1.1.1.1 remote-as 5100
neighbor 1.1.1.1 update-source Loopback1
neighbor 6.6.6.6 remote-as 5600
neighbor 6.6.6.6 ebgp-multihop 2
neighbor 6.6.6.6 next-hop-self
no auto-summary

but this made no change to the bgp table in R1, it still shows the next hop as 6.6.6.6.

the BSCI Office Exam Cert guide states (on page 419) that: 'Typically the next hop will be the address of the edge router, but there are some cases where it makes sense to change this. For instance routes received from external neighbors will be advertised with external next-hop IP address. Internal neighbors might not recognize this as a valid address. The next-hop-self command allows a router to substitute its internal address so that internal neighbors understand how to reach the next-hope address'

obviously i could fix this with some type of IGP or a static route... but im sure i saw in the train signal videos a similar situation where Chris Bryant fixed the problem simply by using the next-hop-self command..

any ideas?

thanks
CCIE# 38186
showroute.net

Comments

  • rakemrakem Member Posts: 800
    bah. Answered my own question. Just had the next-hop-self command in the wrong spot.

    Here is the new R3 config:

    router bgp 5100
    no synchronization
    bgp log-neighbor-changes
    network 33.33.33.0 mask 255.255.255.0
    neighbor 1.1.1.1 remote-as 5100
    neighbor 1.1.1.1 update-source Loopback1
    neighbor 1.1.1.1 next-hop-self
    neighbor 6.6.6.6 remote-as 5600
    neighbor 6.6.6.6 ebgp-multihop 2
    no auto-summary

    changed the next-hop-self to the neighbor 1.1.1.1 instead of 6.6.6.6

    now R1 has valid and best routes to the 66.66.66.0 network and a new next hop address.:

    Network Next Hop Metric LocPrf Weight Path
    *>i22.22.22.0/24 2.2.2.2 0 100 0 i
    *>i33.33.33.0/24 3.3.3.3 0 100 0 i
    *>i44.44.44.0/24 3.3.3.3 0 100 0 5600 5500 5400 i
    *>i55.55.55.0/24 3.3.3.3 0 100 0 5600 5500 i
    *>i66.66.66.0/24 3.3.3.3 0 100 0 5600 i
    R1#

    YAY.
    CCIE# 38186
    showroute.net
  • dtlokeedtlokee Member Posts: 2,378 ■■■■□□□□□□
    eBGP peers already use the idea of "next-hop-self" when they advertise prefixes to peers, you only need next-hop-self on iBGP sessions when the peer doesn't have a route to the eBGP neighbor router.
    The only easy day was yesterday!
Sign In or Register to comment.