From: syv (syv@911networks.com)
Date: Sat Nov 09 2002 - 19:30:30 GMT-3
On Saturday, November 09, 2002, "Erling Bjxntegerd (Privat)" wrote:
Thanks and outstanding!
BTW, my study notes are at:
www.911networks.com/cisco.htm
If you see any error, please let me know.
-----Original Message-----
EBP> The * means any occurence of the char including none.
EBP> The + means at least one occurence of the char should be present.
EBP> This means that [0-9]* also cover routes orginated from this AS.
EBP> See following printout:
EBP> rA#sh ip bgp
EBP> BGP table version is 6, local router ID is 172.16.10.1
EBP> Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
EBP> Origin codes: i - IGP, e - EGP, ? - incomplete
EBP> Network Next Hop Metric LocPrf Weight Path
*>> 172.16.1.0/24 10.0.0.2 0 0 2 i
*>> 172.16.2.0/24 10.0.0.2 0 0 2 100 i
*>> 172.16.3.0/24 10.0.0.2 0 0 2 200 100 i
*>> 172.16.4.0/24 10.0.0.2 0 0 2 300 200 100 i
*>> 192.168.1.0 0.0.0.0 0 32768 i
EBP> rA#sh ip bgp regexp .*
EBP> BGP table version is 6, local router ID is 172.16.10.1
EBP> Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
EBP> Origin codes: i - IGP, e - EGP, ? - incomplete
EBP> Network Next Hop Metric LocPrf Weight Path
*>> 172.16.1.0/24 10.0.0.2 0 0 2 i
*>> 172.16.2.0/24 10.0.0.2 0 0 2 100 i
*>> 172.16.3.0/24 10.0.0.2 0 0 2 200 100 i
*>> 172.16.4.0/24 10.0.0.2 0 0 2 300 200 100 i
*>> 192.168.1.0 0.0.0.0 0 32768 i
EBP> rA#sh ip bgp regexp ^[0-9]*$
EBP> BGP table version is 6, local router ID is 172.16.10.1
EBP> Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
EBP> Origin codes: i - IGP, e - EGP, ? - incomplete
EBP> Network Next Hop Metric LocPrf Weight Path
*>> 172.16.1.0/24 10.0.0.2 0 0 2 i
*>> 192.168.1.0 0.0.0.0 0 32768 i
EBP> rA#sh ip bgp regexp ^[0-9]+$
EBP> BGP table version is 6, local router ID is 172.16.10.1
EBP> Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
EBP> Origin codes: i - IGP, e - EGP, ? - incomplete
EBP> Network Next Hop Metric LocPrf Weight Path
*>> 172.16.1.0/24 10.0.0.2 0 0 2 i
EBP> rA#sh ip bgp regexp ^$
EBP> BGP table version is 6, local router ID is 172.16.10.1
EBP> Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
EBP> Origin codes: i - IGP, e - EGP, ? - incomplete
EBP> Network Next Hop Metric LocPrf Weight Path
*>> 192.168.1.0 0.0.0.0 0 32768 i
EBP> rA#sh ip bgp regexp [0-9]*
EBP> BGP table version is 6, local router ID is 172.16.10.1
EBP> Status codes: s suppressed, d damped, h history, * valid, > best, i - internal
EBP> Origin codes: i - IGP, e - EGP, ? - incomplete
EBP> Network Next Hop Metric LocPrf Weight Path
*>> 172.16.1.0/24 10.0.0.2 0 0 2 i
*>> 172.16.2.0/24 10.0.0.2 0 0 2 100 i
*>> 172.16.3.0/24 10.0.0.2 0 0 2 200 100 i
*>> 172.16.4.0/24 10.0.0.2 0 0 2 300 200 100 i
*>> 192.168.1.0 0.0.0.0 0 32768 i
EBP> rA#
EBP> Regards
EBP> Erling Bjontegard
EBP> ----- Original Message -----
EBP> From: "syv" <syv@911networks.com>
EBP> To: "Franck ccie" <cciefrank@hotmail.com>
EBP> Cc: <ccielab@groupstudy.com>
EBP> Sent: Saturday, November 09, 2002 6:09 PM
EBP> Subject: Re: Regular expression for BGP
>> On Saturday, November 09, 2002, Franck ccie wrote:
>>
>> -----Original Message-----
>> Fc> I'm looking for a good site giving a good explanation of
>> Fc> regular expression for BGP ..
>>
>> [0-9]* Matches any single AS number. This is the wild card for an AS
>> _.* Matches everything [permit any/all]
>> _100_ Any route going through AS100
>> _100 200_ Passed through 100 and 200 in that order
>> _100$ Any route originated in AS100
>> ^100$ Only routes originated in AS100 that did not pass through any other AS
>> ^100_ Only routes received from AS100, anything else behind
>> ^100 .* Only routes received from AS100, anything else behind [alternative]
>> ^$ Originated from this AS
>> ( .*) matches a space plus a AS.
>> ( .*)* matches a space plus a AS or a null string.
>> ? To type ?: either Ctrl-V or Esq-Q
>>
>>
>> --
>> Thanks
>> syv@911networks.com
>>
>>
-- Thanks syv@911networks.com
This archive was generated by hypermail 2.1.4 : Tue Dec 03 2002 - 07:22:55 GMT-3