Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 
New Member

BGP as_path manipulation


I wonder if there is a way to manipulate the BGP as_path or make BGP process ignore same AS values/numbers in the as_path.

Problem: 2 VPNs in the same MPLS Backbone. I interconect them (on the CE side of the VPNs) with the e-BGP (have FW in between the CEs) and the same AS numbers of on VPN pop up again in the other VPN but the same MPLS (same BGP AS).

I need to ignore them somehow on the PE routers or better remove/suppress them.



New Member

Re: BGP as_path manipulation


If you use 'bgp bestpath as-path ignore' command, it will skip this step during best path selection. Also you can use 'neighbor as-override' command to override a site's AS. In addition to these commands, you can use allow as-in option to override loop checking mechanism that use as-path atributes. This allows taking NLRIs into BGP table that consist own ASN.

New Member

Re: BGP as_path manipulation

Thanks for response.

I see 'bgp bestpath as-path ignore' and 'allow as-in' as the solutions however found no proper documentation to find out more about the commands (only command refs, which is not enough). I imply need to know wethere these commands would wokr in the MPLS network on the PE routers at BGP VPNv4 VRF level and what IOS-es and router platforms support them.

Would be good to have more info + experience comments

thanks !

New Member

Re: BGP as_path manipulation

"allowas-in" is better option cos it has option of specifying how many time the as can be advertised.

syntax: neighbor allowas-in (number)

Both the commands are supported in IOS 12.x

For more information u can visit following link



Nikhil E.

New Member

Re: BGP as_path manipulation

Thank you all.

One thing is not clear to me.

If the BGP prefix update already has an AS number and tries to enter the domain with the same AS number, would it be accepted as a result of the command "allowas-in" connfigured on the PE router ?


CreatePlease to create content