01-11-2015 03:51 PM - edited 03-05-2019 12:32 AM
Hello,
I have 3 routers
r1 - AS 100
R2 - AS 200
R3 - AS 200
R1 Connected direct to R2 via EBGP. R2 Connects to R3 via IBGP I advertise a loopback 1.1.1.1/32 on r1 router3 will not see this as there is no valid route as the next hop is the outgoing interface of r1 which I cannot ping so I use the next hop self command between r2 and r3 which works well.
I have got the same setup however I have removed the network command an advertised the network via redistribute connected within BGP for some reason I don't need the next hop self command and I can ping the loopback no problem any idea why this is??
Hope someone can clear this up also I'm not using any IGP
Thanks
Solved! Go to Solution.
01-12-2015 07:43 AM
Hello,
It is because when you do the redistribute connected, by default, you are advertising all the connected networks through BGP. Therefore, you are advertising both the loopback of R1 and the link connected to R2 (R1-R2). The same result would be to announce the loopback and the connected link R1-R2 via the network command.
The only difference between both commands is that with "network" you will advertise the prefixes with origin IGP and with "redistribute" with origin "incomplete". Take this into account for the BGP Best Path Selection: IGP>incomplete.
Typically, you have a better control with "network" instead of "redistribute". However, when you want to advertise a lot of prefixes, it is useful the redistribute and you can always add a route-map to control the prefixes you want to inject in BGP.
Hope this helps,
Jose.
01-12-2015 07:29 AM
First of all I suppose you are advertising networks between R2 and R3 to R1 via eBGP. In any case there is no reason why it has to work using redistribution. It made a little test and, as supposed, it doesn't work. Could you please post you configuration ?
Bye,
enrico
01-12-2015 07:43 AM
Hello,
It is because when you do the redistribute connected, by default, you are advertising all the connected networks through BGP. Therefore, you are advertising both the loopback of R1 and the link connected to R2 (R1-R2). The same result would be to announce the loopback and the connected link R1-R2 via the network command.
The only difference between both commands is that with "network" you will advertise the prefixes with origin IGP and with "redistribute" with origin "incomplete". Take this into account for the BGP Best Path Selection: IGP>incomplete.
Typically, you have a better control with "network" instead of "redistribute". However, when you want to advertise a lot of prefixes, it is useful the redistribute and you can always add a route-map to control the prefixes you want to inject in BGP.
Hope this helps,
Jose.
01-12-2015 08:03 AM
Just if you config redistribute connected also on R2, otherwise network between R1 and R2 is advertised to R3 with next hop R1 and, again, R3 does not know R1 address.
enrico
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide