cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
476
Views
0
Helpful
4
Replies

question in BGP route map ?

Dr.X
Level 2
Level 2

hi ,

im using bgp protocol , and here is my config on my production network , "" i hided the ips with xx for privacy""

%%%%%%%%%%%%%%%%%%%%%%%%%%

router bgp xx99xx

no synchronization

bgp log-neighbor-changes

network xx.xx.64.0 mask 255.255.254.0

network xx.xx.64.0 mask 255.255.255.0

network xx.xx.65.0 mask 255.255.255.0

network xx.xx.66.0 mask 255.255.254.0

network xx.xx.68.0 mask 255.255.252.0

network xx.xx.72.0 mask 255.255.252.0

network xx.xx.76.0 mask 255.255.252.0

redistribute connected

redistribute static

neighbor xx.1xx.56.165 remote-as xxxx

neighbor 1xx6.xx5.56.165 route-map e1 out

neighbor xx.xx4.66.77 remote-as xxxx

neighbor 2xx.xx4.66.77 route-map e2 out

no auto-summary

as you see from my config above  , im  adverstsing in general alot of networks ,  but im using router map with  my two neighbours

my question is ,

does the lines

network xx.xx.64.0 mask 255.255.254.0

network xx.xx.64.0 mask 255.255.255.0

network xx.xx.65.0 mask 255.255.255.0

network xx.xx.66.0 mask 255.255.254.0

network xx.xx.68.0 mask 255.255.252.0

network xx.xx.72.0 mask 255.255.252.0

network xx.xx.76.0 mask 255.255.252.0

has no meaning  beacuse im using router map ???  " can i remove these lines ???"

does

redistribute connected

redistribute static

can be removed without affecting any thing in bgp ???

i want to reove them if they has no meaning but im afraid becuse im on production network

with my best regards

1 Accepted Solution

Accepted Solutions

Hello Ahmed,

the BGP session would still be up but the risk is that you can remove IP networks that you are advertising to your neighbors and this would have an impact.

These network commands provide the content ( = routes in the BGP table) the route-maps applied to neighbor sessions select between existing routes in BGP table  what routes to advertise to the neighbor but they cannot create a route on the fly.

For clarity: If a ruote is removed from the BGP table it cannot be advertised anymore even if it is permitted in the route-map applied on the BGP session to the neighbor.

For this reason you have to check what is needed.

Hope to help

Giuseppe

View solution in original post

4 Replies 4

Giuseppe Larosa
Hall of Fame
Hall of Fame

Hello Ahmed,

the route-maps applied to the eBGP neighbors have the purpose to perform route filtering, that is among all the BGP routes that are present in the BGP table only those that match in the route-map in permit clauses ( route-map e1 permit 10 for example) are actually advertised to the neighbor.

The network commands and the redistribute commands have the purpose to populate the BGP table with locally inejcted routes and should include the IP networks advertised to eBGP neighbors.

Generally speaking in BGP within the limit of the max number of network statements (200) there is no need of using redistribute statement for connected or static or even for routing protocols like OSPF, EIGRP.

You cannot remove all the statements or the risk is to advertise less or even none route to eBGP neighbors.

By checking the two route-maps applied to eBGP neighbors and the list of BGP networks with show ip bgp looking for those networks with IP next-hop = 0.0.0.0 ( means locally generated) you can understand what commands have to be kept and what could be removed.

It is likley that you can remove the two redistribute statements but without checking is not safe to remove them

Hope to help

Giuseppe

hi ,

you mean that the filtering isdone to filter the  lines which are put under the bgp route command

you mean that if i removed all the lines below

network xx.xx.64.0 mask 255.255.254.0

network xx.xx.64.0 mask 255.255.255.0

network xx.xx.65.0 mask 255.255.255.0

network xx.xx.66.0 mask 255.255.254.0

network xx.xx.68.0 mask 255.255.252.0

network xx.xx.72.0 mask 255.255.252.0

network xx.xx.76.0 mask 255.255.252.0

the bgp will fail ???

is that reight ??

Hello Ahmed,

the BGP session would still be up but the risk is that you can remove IP networks that you are advertising to your neighbors and this would have an impact.

These network commands provide the content ( = routes in the BGP table) the route-maps applied to neighbor sessions select between existing routes in BGP table  what routes to advertise to the neighbor but they cannot create a route on the fly.

For clarity: If a ruote is removed from the BGP table it cannot be advertised anymore even if it is permitted in the route-map applied on the BGP session to the neighbor.

For this reason you have to check what is needed.

Hope to help

Giuseppe

thanks soo much

i nailed it down

regards

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Innovations in Cisco Full Stack Observability - A new webinar from Cisco