Newbie BGP Problems

Hey everyone,

I’m a total newbie to BGP and am having problems after the BGP routes are sent across to the network.

My test network (went for the simplest little network possible) is like so:

FirstBox->SecondBox->ThirdBox

All of them being metarouters with the right ether* forwarded to one another.

My main goal is to send a packet from FirstBox to ThirdBox with BGP determining the first hop.


I’ve got the following in SecondBox:

Flags: X - disabled, A - active, D - dynamic, C - connect, S - static, r - rip, b - bgp, o - ospf, m - mme, B - blackhole, U - unreachable, P - prohibit 
 0 ADC  dst-address=10.1.1.0/24 pref-src=10.1.1.2 gateway=ether1 gateway-status=ether1 reachable distance=0 scope=10 

 1 ADC  dst-address=10.1.2.0/24 pref-src=10.1.2.1 gateway=ether2 gateway-status=ether2 reachable distance=0 scope=10 

 2 A S  dst-address=10.10.10.1/32 gateway=10.1.1.1 gateway-status=10.1.1.1 reachable ether1 distance=1 scope=30 target-scope=10 

 3 ADC  dst-address=10.10.10.2/32 pref-src=10.10.10.2 gateway=lobridge gateway-status=lobridge reachable distance=0 scope=10 

 4 A S  dst-address=10.10.10.3/32 gateway=10.1.2.2 gateway-status=10.1.2.2 reachable ether2 distance=1 scope=30 target-scope=10

And networks that it announces:

Flags: X - disabled 
 0   network=10.1.2.0/24 synchronize=yes 

 1   network=10.1.1.0/24 synchronize=yes

And in ThirdBox, the final routes it has:

Flags: X - disabled, A - active, D - dynamic, C - connect, S - static, r - rip, b - bgp, o - ospf, m - mme, B - blackhole, U - unreachable, P - prohibit 
 0 ADb  dst-address=10.1.1.0/24 gateway=10.10.10.2 gateway-status=10.10.10.2 recursive via 10.1.2.1 ether1 distance=200 scope=40 target-scope=30 bgp-local-pref=100 bgp-origin=igp received-from=ch 

 1 ADC  dst-address=10.1.2.0/24 pref-src=10.1.2.2 gateway=ether1 gateway-status=ether1 reachable distance=0 scope=10 

 2  Db  dst-address=10.1.2.0/24 gateway=10.10.10.2 gateway-status=10.10.10.2 recursive via 10.1.2.1 ether1 distance=200 scope=40 target-scope=30 bgp-local-pref=100 bgp-origin=igp received-from=ch 

 3 A S  dst-address=10.10.10.2/32 gateway=10.1.2.1 gateway-status=10.1.2.1 reachable ether1 distance=1 scope=30 target-scope=10 

 4 ADC  dst-address=10.10.10.3/32 pref-src=10.10.10.3 gateway=lobridge gateway-status=lobridge reachable distance=0 scope=10

When doing a traceroute from ThirdBox to FirstBox (10.10.10.1) I get this:

 # ADDRESS                                 RT1   RT2   RT3   STATUS                                                                                                                                       
 1 10.1.2.1                                2ms   1ms   2ms                                                                                                                                                
 2 0.0.0.0                                 0ms   0ms   0ms

(with 10.1.2.1 being the ethernet of the SecondBox)

Any help with this would be very, very much appreciated.

Thanks

synchronize=yes – read what this does.

andy

Are you doing ‘/tool traceroute src-address=10.10.10.2 10.10.10.1’ ?

What’s the routing table from the first box look like?

This question managed to get it working for me! Thanks! Looks like the bgp peer on SecondBox for FirstBox wasn’t established for some reason, but disabling and re-enabling that peer got it Established.

Now, I added a network on SecondBox:

/routing bgp network add network=10.10.10.0/24

And made sure it was enabled, and it appears in the list:

 0   network=10.1.2.0/24 synchronize=yes 

 1   network=10.1.1.0/24 synchronize=yes 

 2   network=10.10.10.0/24 synchronize=yes

But it isn’t being received on FirstBox (even after reboot and checking that the bgp peer is established):

 0 ADC  dst-address=10.1.1.0/24 pref-src=10.1.1.1 gateway=ether1 gateway-status=ether1 reachable distance=0 scope=10 

 1  Db  dst-address=10.1.1.0/24 gateway=10.10.10.2 gateway-status=10.10.10.2 recursive via 10.1.1.2 ether1 distance=200 scope=40 target-scope=30 bgp-local-pref=100 bgp-origin=igp received-from=SecondBox

 2 ADb  dst-address=10.1.2.0/24 gateway=10.10.10.2 gateway-status=10.10.10.2 recursive via 10.1.1.2 ether1 distance=200 scope=40 target-scope=30 bgp-local-pref=100 bgp-origin=igp received-from=SecondBox

 3 ADC  dst-address=10.10.10.1/32 pref-src=10.10.10.1 gateway=lobridge gateway-status=lobridge reachable distance=0 scope=10 

 4 A S  dst-address=10.10.10.2/32 gateway=10.1.1.2 gateway-status=10.1.1.2 reachable ether1 distance=1 scope=30 target-scope=10

Is there any way of doing more diagnostics on this? Is there any way to get a better look at what is going on behind the scenes with BGP?

Thanks!

Ignore the post I just posted (it’s awaiting moderators), this fixed it - you my friend are a legend.

I can now successfully ping 10.10.10.3 from 10.10.10.1!

New problem - thought I wouldn’t clutter the Forwarding section with noobie problems.

http://imgur.com/ooVHR

I have that setup going on my desk right next to me, with 4 devices and start a ping from Source to Destination.

Originally it begins going through SecondRouter to Destination, and then I unplug SecondRouter->Destination to test failover, which it then fails over to the SecondRouter->FirstRouter link, and then down to Destination.

Then I unplug Secondrouter->FirstRouter, and the Source continues to send stuff through to SecondRouter, even though he shouldn’t be advertising the network anymore (is there a more bgp way of doing this?)

Realistically, when all this fails, I’d like it to jump to FirstRouter and then to Destination.

So I guess my question is, is there a way to get SecondRouter to stop advertising an IP if it can’t actually reach it? I’ve tried check-gateway=ping and that seems to work, but it keeps advertising my network.

Thanks