BGP problem

Answered Question
Jan 24th, 2009

Dear All,

I am trying to configure BGP between 2 routers, but for some reason I am not getting routes from other end. I have configured everything at both ends including no sync and no auto-summary. My neighborship is also getting successfully built. But for some reason I am not getting routes. but whenever I am adding "ip route x.x.0.0 255.255.0.0 Null0" this command I am immediately getting all routes.

Please need urgent help.

Thanks and regards,

Mangesh.

I have this problem too.
0 votes
Correct Answer by Mohamed Sobair about 7 years 10 months ago

Mangesh,

This is in fact because the prefixes you are trying to advertise were not installed in the IP routing table. In order to do so, you should add those static routes pointing to null0 with high Administrative distance to eleminate your router dropping the Packets destined for those Prefixes. Or You dont have to do so if and ONLY if the routes are directly connected.

Synchronization has nothing to do with that in any case. Synchronization rule stays: "a BGP Speaker shall not advertise any BGP learned routes to any EBGP neighbor unless the routes are validated by the IGP".

No auto-summary has also nothing to do with that, The auto-summary command Only affects redistributed routes into BGP.

I hope I am informative.

Mohamed

Correct Answer by Giuseppe Larosa about 7 years 10 months ago

Hello Mangesh,

the BGP next-hop must be known or the BGP advertisement is not installed

if using no auto-summary the network command in BGP needs to match the real ip subnet

router bgp XX

network 192.168.2.0

look in routing tabel for 192.168.2.0/24 (major network boundary)

router bgp XX

network 192.168.3.0 255.255.255.128

BGP looks for 192.168.2.0/25 and advertises it if it founds in routing table

so depending on the usage of a subnet of a major subnet and/or auto-summary settings you may need a network command with a mask

Edit:

for sure you haven't placed a /16 on an interface but a subnet of this /16.

then you may use an aggregate command with summary-only to have only the /16 advertised.

Hope to help

Giuseppe

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 2.5 (2 ratings)
Loading.
Jon Marshall Sat, 01/24/2009 - 04:31

Mangesh

Is the IBGP or EBGP. No sync only affects IBGP.

If it is EBGP and you are using network statements under your BGP config then there must be a route in the IGP routing table for that network to be advertised - regardless of sync or no sync.

If you add "ip route x.x.0.0 255.255.0.0 Null0" then in effect you are adding a rouet into the IGP routing table and so BGP can advertise out that network.

Jon

mangesh.kamble Sat, 01/24/2009 - 04:36

hi Jon,

Thanks for your reply. Well, I understand what you want to convey related to Sync command. But now in my bgp configuration I am having a command " network x.x.0.0 mask 255.255.0.0 " ok. and beneath that outside bgp I have a command "ip route x.x.0.0 255.255.0.0 null0". Without this Null 0 command I don't get any routes. This is my problem.

Can you please help me.

Thanks and Regards,

Mangesh.

Jon Marshall Sat, 01/24/2009 - 04:52

Mangesh

That's exactly what i was explaining to you. Can you confirm this is EBGP ?

For a BGP router to advertise a network that you have configured using the "network x.x.0.0 mask 255.255.0.0" to another EBGP peer there must be an exact match in the routing table for this network.

If there was already a route there then it should have advertised it out. If there wasn't, by adding the route to Null0 it then allowed the router to advertise it out.

Jon

mangesh.kamble Sat, 01/24/2009 - 04:59

Hi Jon,

Yeah this is Ebgp. There is no similar route initially present. We have added this ip address to one of the interface on that router. And then we are advertising it into BGP. Also currently there is no IGP running, except this static route.

And moreover, if we remove this static command we are not able to receive any of the routes.

So please help me.

Thanks and Regards,

Mangesh.

Correct Answer
Giuseppe Larosa Sat, 01/24/2009 - 05:11

Hello Mangesh,

the BGP next-hop must be known or the BGP advertisement is not installed

if using no auto-summary the network command in BGP needs to match the real ip subnet

router bgp XX

network 192.168.2.0

look in routing tabel for 192.168.2.0/24 (major network boundary)

router bgp XX

network 192.168.3.0 255.255.255.128

BGP looks for 192.168.2.0/25 and advertises it if it founds in routing table

so depending on the usage of a subnet of a major subnet and/or auto-summary settings you may need a network command with a mask

Edit:

for sure you haven't placed a /16 on an interface but a subnet of this /16.

then you may use an aggregate command with summary-only to have only the /16 advertised.

Hope to help

Giuseppe

Correct Answer
Mohamed Sobair Sat, 01/24/2009 - 07:01

Mangesh,

This is in fact because the prefixes you are trying to advertise were not installed in the IP routing table. In order to do so, you should add those static routes pointing to null0 with high Administrative distance to eleminate your router dropping the Packets destined for those Prefixes. Or You dont have to do so if and ONLY if the routes are directly connected.

Synchronization has nothing to do with that in any case. Synchronization rule stays: "a BGP Speaker shall not advertise any BGP learned routes to any EBGP neighbor unless the routes are validated by the IGP".

No auto-summary has also nothing to do with that, The auto-summary command Only affects redistributed routes into BGP.

I hope I am informative.

Mohamed

mangesh.kamble Sat, 01/24/2009 - 10:27

Dear All,

Thanks for all your informative replies. That really helped me.

Thanks and Regards,

Mangesh.

Actions

This Discussion