cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
974
Views
7
Helpful
4
Replies

Rewritting AS path

cisco_lad2004
Level 5
Level 5

Dear all,

Though its unsafe to start tampering with AS path, I am in a situation where I need to get rid of a private AS that is appended right behind a public AS.

IOS see this as a config error and remove-private-as becomes obsolete ( junos does not).

I came across few posts with the command "set as-path exclude" but cannot seem to find any more info about it on Cisco.com.

Any thoughts or pointers ?

TIA

Sam

4 Replies 4

milan.kulik
Level 10
Level 10

Hi,

AFAIK, once you are receiving a mixture of public and private AS numbers within the AS-PATH, the only way to remove the private one(s) is to remove the AS-PATH completely by redistributing to an IGP and manipulate the AS-PATH when redistributing back from IGP to BGP.

Which is quite complicated and requires multiple routers (or VRFs) involved.

BR,

Milan

francisco_1
Level 7
Level 7

The command to perform AS_PATH striping is "neighbor remove-private-as". All BGP updates sent over this sesssion are inspected to have a sequence of private  AS numbers in the beginning of the AS_PATH. All private numbers are removed and the local AS number is prepended.

By the way are you using the private AS number? you ISP should remove that when they advertise your prefixes!!

Francisco.

@francisco_1:

neighbor remove-private-as" command fails in a case of the AS-PATH containing a mixture of private and public AS numbers :-(

BR,

Milan

Thank you both for the replies !

I considered BGP>IGP>BGP redistribution which a workaround...but opted for a cleaner design which was to simply redesign my set up and avoid a mix of Private and public ASs.

Thanks

Sam

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: