BGP Network Advertisements

Unanswered Question
Jan 13th, 2009

Hello,

Is it possible to use route-maps with ip-prefix-lists as well as bgp network command to advertise networks to bgp-peers? If so which is preferred? Or do they work together?

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 3.5 (4 ratings)
Loading.
Marwan ALshawi Tue, 01/13/2009 - 17:42

hi Jesse

at the begining with BGP u there tow ways for advertisemnts to nighbers

either the route learned from other BGP or EBGP npeers then will be passed by the router to other peers or the bgp router has this route insstalled through directly connected network or any IGP such as ospf

this way you can make advertisment by useing network command

now lets take first case u dont have network but u send route learned from other peer

if u wanna filter this route and send it out to ur peer u can do it by useing a route map

aslo if u advertised a route by useing network command and wanna to filter this route to no to be sent to a peer and send part off it to other peers by useing route map with prefix-list

this way u use them all

then they all work togther to achieve the routing requirements advertisment or filteriing

u can filter based on AS number or prefix list or ACL

also u can use advnced comunity attributes to control inbound and outbound traffic with bgp and route maps

good luck

if helpful Rate

Jesse Hottle Tue, 01/13/2009 - 19:45

Hello,

If use a route-map for my OUT advertisements, do I still need to specify the networks?

Example:

router bgp 1

network 1.1.1.1 mask 255.255.255.0

network 2.2.2.2 mask 255.255.255.0

neighbor 10.0.0.0 remote-as 2

neighbor 10.0.0.0 route-map EBGP_OUT out

route-map EBGP_OUT permit 5

match ip address prefix-list advertise

ip prefix-list advertise seq 5 permit 1.1.1.1/24

ip prefix-list advertise seq 10 permit 2.2.2.2/24

Marwan ALshawi Tue, 01/13/2009 - 19:52

based on the above config only traffic permited by the route map will go out to that spesific peer whihc is 10.0.0.1 (10.0.0.0 worng host address)

anyway

route map dosnt do any advertisment but it help you make changes on the advertised route or filter advertised route

u can make filtering by prefix-lis as well by useing filter-list command

in the above example if u have other networks advertised in that bgp route they will not go to the 10.0 peer as there is implicit deny at the end of the route map this will what u have permited will be passed and anything els will be denied

if u wana do the opisted for example deny those prefixes from being advertised and permite anything els u cloud do it like

route-map EBGP_OUT deny 5

match ip address prefix-list advertise

route-map EBGP_OUT permit 10

hope this helps

Jesse Hottle Tue, 01/13/2009 - 20:05

Thats helps.

I was just curious because on an ImageStream router for example, you still have to specify the prefix u wish to advertise with the network command, using a route map or not.

So basically if a route-map is applied with the neighbor command it takes precedence over any other network statements?

One thing I am trying to do is prepend some of the advertised prefixes to make a preferred route. Any special things I should know there in regards to Cisco? Sry for the long winded questions.

Marwan ALshawi Tue, 01/13/2009 - 20:10

first when i seen the tating i thought i was not helpful because 1 means not helpful !!

please rate it acordengly please

ok for route map with network

it is not precedence matter it like

u have a router advertise 5 routes and u want to filter out 2 of them you can do it by matching those routes by a prefix list of ACL then put it in a route map then use the route map in ur bgp to let it dose the filtering

for making prefrence for traffic advertised to nieghbors there group of bgp attrebutes that effect the inbound and out bound

give me a topology and i can help you which way you can do it

mentioning the route direction

hope this helps

Jesse Hottle Tue, 01/13/2009 - 20:26

This is more than helpful. Also, I have not rated anything yet, but will for sure.

I have attached a topology diagram. Preferred routes are to go through AS200. I am more looking at using route-maps to control advertisements. Does that help?

Marwan ALshawi Tue, 01/13/2009 - 20:41

thanks for rating

first u want the prefrence applied to traffic coming from both ISPs to go thorugh AS200

or traffic from ur inside netwrok going to a learned prefix from both ASs to go through AS 200

lets say u see 20.0.0.0 from as 100 and as 200

and u wan traffic from inside going thorugh ur network use as 200 as prefered path ?

if this is the case and u have one router as the edge router u with tow links

u can use wieght attribute the assigen higher wight to traffic learned from as 200 then it will be prefered

this is works on cisco router only

bellow is very useful link read it and will help u to understand all the things u were asking about

if u have any question just post it here

http://www.cisco.com/en/US/tech/tk365/technologies_configuration_example09186a00800945bf.shtml

good lcuk

ahmad82pkn Wed, 01/14/2009 - 06:56

hi marwanshawi , i have a small question regarding, first example scenario of cisco link provided above,

first example claims to be BGP load balancing, but actually its doing eigrp load balancing, then how can we call it BGP load balancing? :-s

Marwan ALshawi Wed, 01/14/2009 - 13:12

ok good question

the routes between routers learned via IGP lets say eigrp

but the same networks reachable via EBGP then eigrp will used to reach those networks and get it installed in local routing table but ebgp will be considered for routing traffic as EBGP admistrative distance is less than eigrp or ospf

hope this helps

Actions

This Discussion