Junos OS

last person joined: 22 hours ago 

Ask questions and share experiences about Junos OS.
  • 1.  EBGP Regular Expressions

    Posted 03-08-2011 23:21

    Hello Community

     

    Can some one please help me defining the Regex for following conditions.

     

    1- All routes sourced from as AS

     

    2-All routes that transited an AS.

     

    To me the Rgex for Condition number 1 wil be

     

    ".*ASnumber" As the routes sourced from a prticular AS will have that AS as number attached at the right most of Aspath.

     

    2- ".*ASnumber.*" as the routes that transited a particular AS will be somewhere in between the first and last AS.

     

    What do you guys think is it alright.

     

    Thanks & Regards

     

    Malik



  • 2.  RE: EBGP Regular Expressions
    Best Answer

    Posted 03-09-2011 10:21

    That looks right - depending on how you implement exactly.

     

    An AS path regex of '.* 65500' will match all AS paths that end in 65500.  (e.g. '65500', '65499 65500')

     

    An AS path regex of '.* 65500 .*' will match all AS paths that contain/transit 65500.  Note: this will also include AS paths originating from AS 65500.  (e.g. '65500' '65499 65500', '65499 65500 65501')

     

    You just have to remember when creating your policy statements that if you perform a non-terminating action on regex #1, originating AS paths would also match regex #2.



  • 3.  RE: EBGP Regular Expressions

    Posted 03-09-2011 21:53

    You'll need ".* 65000$" for originating.



  • 4.  RE: EBGP Regular Expressions

    Posted 03-09-2011 23:18

    Hello Hanks

     

    Can you please elaborate a bit.Thank you

     

    Regards

     

    Malik



  • 5.  RE: EBGP Regular Expressions

    Posted 03-10-2011 05:01

    The '.* 65500$' expression is a little more explicit - the '$' signifies the end of the AS path.  However, I believe the use of this character is optional, as it is added implicitly in Junos.



  • 6.  RE: EBGP Regular Expressions