cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1159
Views
0
Helpful
2
Replies

How to filter transit AS via Regex - eBGP

dc-csa-blr
Level 1
Level 1

Dear Experts,

We're using multiple upstream providers bandwidth in single homed with eBGP routing, what configuration to help accept only connected upstream provider AS to avoid Transit AS in eBGP, via regex   and also how can i filter to advertise connected upstream provider my private prefix and other prefix except my public IP.  

ISP -1 AS : 111

ISP-2 AS :  222

ISP-3 AS :  333

Our AS - 123

Our Public IP : 5.5.5.0/22 , 6.6.6.0/22 , 7.7.7.0/22

PFA - Diagram for more understanding.

Please help to get it resolve.

Thanks in ADV,

1 Accepted Solution

Accepted Solutions

Pawan Raut
Level 4
Level 4

1)what configuration to help accept only connected upstream provider AS to avoid Transit AS in eBGP==> If I get you correctly you want  route which is connected to upstream ISP and not from other then you can do this. You can change the BGP expression as per your requirement reference is http://blog.ine.com/2008/01/06/understanding-bgp-regular-expressions/

ip as-path access-list 1 permit ^111$ 
!
route-map IN_FRPM_ISP1 permit 10
match as-path 1
!

router bgp XXX
nei x.x.x.x route-map IN_FRPM_ISP1 IN

!

2)how can i filter to advertise connected upstream provider my private prefix and other prefix except my public IP ==> allow only your Pulic subnet to be advtised to upstream provider so est private subnet will not advrtised.

ip prefix-list test seq 5 permit  5.5.5.0/22

ip prefix-list test seq 5 permit  6.6.6.0/22

ip prefix-list test seq 5 permit  7.7.7.0/22

!

router bgp XXX
nei x.x.x.x prefix-list test out

!

Kindly rate for usefulpost

View solution in original post

2 Replies 2

Pawan Raut
Level 4
Level 4

1)what configuration to help accept only connected upstream provider AS to avoid Transit AS in eBGP==> If I get you correctly you want  route which is connected to upstream ISP and not from other then you can do this. You can change the BGP expression as per your requirement reference is http://blog.ine.com/2008/01/06/understanding-bgp-regular-expressions/

ip as-path access-list 1 permit ^111$ 
!
route-map IN_FRPM_ISP1 permit 10
match as-path 1
!

router bgp XXX
nei x.x.x.x route-map IN_FRPM_ISP1 IN

!

2)how can i filter to advertise connected upstream provider my private prefix and other prefix except my public IP ==> allow only your Pulic subnet to be advtised to upstream provider so est private subnet will not advrtised.

ip prefix-list test seq 5 permit  5.5.5.0/22

ip prefix-list test seq 5 permit  6.6.6.0/22

ip prefix-list test seq 5 permit  7.7.7.0/22

!

router bgp XXX
nei x.x.x.x prefix-list test out

!

Kindly rate for usefulpost

dc-csa-blr
Level 1
Level 1

Thanks for your great help.

Review Cisco Networking products for a $25 gift card