From: dara tomar (wish2ie@gmail.com)
Date: Wed Aug 20 2008 - 02:50:16 ART
Hi Huan,
The importance and the significance of the quote-regexp comes in when you
specify the regexp filtering the show o/p of the command.
eg,
1>Normal regexp:
--------------------------
route-views.oregon-ix.net>sh ip bgp regexp _4755$
BGP table version is 2165510, local router ID is 198.32.162.100
Status codes: s suppressed, d damped, h history, * valid, > best, i -
internal,
S Stale
Origin codes: i - IGP, e - EGP, ? - incomplete
Network Next Hop Metric LocPrf Weight Path
* 59.151.144.0/22 196.7.106.245 0 0 2905 702 6453
4755 i
* 12.0.1.63 0 7018 6453 4755
i
* 64.71.255.61 0 812 6453 4755 i
* 134.222.87.1 0 286 6453 4755 i
* 203.62.252.186 0 1221 4637 6453
4755 i
* 66.59.190.221 0 6539 6453 4755
i
* 129.250.0.171 1 0 2914 6453 4755
i
* 129.250.0.11 3 0 2914 6453 4755
i
* 202.249.2.86 0 7500 2516 4755
i
* 66.185.128.48 514 0 1668 6453 4755
i
* 193.251.245.6 0 5511 6453 4755
i
* 65.106.7.139 3 0 2828 6453 4755
i
* 157.130.10.233 0 701 6453 4755 i
* 193.0.0.56 0 3333 3356 6453
4755 i
* 203.181.248.168 0 7660 2516 4755
i
* 89.149.178.10 10 0 3257 6453 4755
i
* 4.68.1.166 0 0 3356 6453 4755
i
* 154.11.11.113 0 0 852 6453 4755 i
* 154.11.98.225 0 0 852 6453 4755 i
* 64.125.0.137 66 0 6461 6453 4755
i
* 195.219.96.239 0 6453 4755 i
* 207.45.223.244 0 6453 4755 i
* 207.172.6.162 6 0 6079 3356 6453
4755 i
* 209.10.12.125 4103 0 4513 13789 1239
6453 4755 i
* 207.172.6.20 5 0 6079 3356 6453
4755 i
* 134.55.200.1 0 293 6453 4755 i
*> 207.46.32.34 0 8075 4755 i
* 206.24.210.100 0 3561 6453 4755
i
* 208.51.134.254 75 0 3549 6453 4755
i
* 194.85.4.55 0 3277 3267 6453
4755 i
* 217.75.96.60 0 0 16150 1239 6453
4755 i
* 202.232.0.2 0 2497 6453 4755
i
* 195.66.232.239 0 5459 6453 4755
i
* 213.140.32.146 0 12956 6453 4755
i
* 216.218.252.164 0 6939 1299 6453
4755 i
* 59.160.0.0/22 196.7.106.245 0 0 2905 702 6453
4755 i
* 12.0.1.63 0 7018 6453 4755
i
* 64.71.255.61 0 812 6453 4755 i
* 134.222.87.1 0 286 6453 4755 i
* 203.62.252.186 0 1221 4637 6453
4755 i
* 66.59.190.221 0 6539 6453 4755
i
* 129.250.0.171 1 0 2914 6453 4755
i
2>Normal regexp O/P with a filter regexp filtering the show o/p:
------------------------------------------------------------------------------------------
route-views.oregon-ix.net>sh ip bgp regexp _4755$ | i 6461
route-views.oregon-ix.net>
route-views.oregon-ix.net>
3>The quote-regexp coming handy here :) :) :
-------------------------------------------------------------------
route-views.oregon-ix.net>sh ip bgp quote-regexp _4755$ | i 6461
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
* 64.125.0.137 66 0 6461 6453 4755
i
Thanks,
Dara
On Wed, Aug 20, 2008 at 4:53 AM, Huan Pham
<Huan.Pham@peopletelecom.com.au>wrote:
> I do not see any difference between these commands.
>
> The info from command reference for quote-regexp states that "the
> regular expression has to be an exact match.", whereas the other command
> (regexp) does not have this note.
>
> Can anyone please give me an example showing the difference btw the two?
> Thanks.
>
>
>
>
>
>
> route-views.optus.net.au>sh ip bgp regexp _100_
> BGP table version is 39026345, local router ID is 203.202.125.6
> Status codes: s suppressed, d damped, h history, * valid, > best, i -
> internal,
> r RIB-failure, S Stale
> Origin codes: i - IGP, e - EGP, ? - incomplete
>
> Network Next Hop Metric LocPrf Weight Path
> *> 190.54.50.0/24 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 200.14.192.0 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 200.14.215.0 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 208.96.128.0 202.160.242.71 0 7473 3561
> 1239 20299 27742 100 i
> * 210.23.158.70 0 7543 10026
> 1239 20299 27742 100 I
>
>
> route-views.optus.net.au>sh ip bgp quote-regexp _100_
> BGP table version is 39026370, local router ID is 203.202.125.6
> Status codes: s suppressed, d damped, h history, * valid, > best, i -
> internal,
> r RIB-failure, S Stale
> Origin codes: i - IGP, e - EGP, ? - incomplete
>
> Network Next Hop Metric LocPrf Weight Path
> *> 190.54.50.0/24 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 200.14.192.0 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 200.14.215.0 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 208.96.128.0 202.160.242.71 0 7473 3561
> 1239 20299 27742 100 i
> * 210.23.158.70 0 7543 10026
> 1239 20299 27742 100 I
>
>
> route-views.optus.net.au>sh ip bgp quote-regexp "_100_"
> BGP table version is 39026706, local router ID is 203.202.125.6
> Status codes: s suppressed, d damped, h history, * valid, > best, i -
> internal,
> r RIB-failure, S Stale
> Origin codes: i - IGP, e - EGP, ? - incomplete
>
> Network Next Hop Metric LocPrf Weight Path
> *> 190.54.50.0/24 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 200.14.192.0 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 200.14.215.0 202.160.242.71 0 7473 3549
> 28513 6429 100 ?
> * 210.23.158.70 0 7543 10026
> 3356 28513 6429 100 i
> *> 208.96.128.0 202.160.242.71 0 7473 3561
> 1239 20299 27742 100 i
> * 210.23.158.70 0 7543 10026
> 1239 20299 27742 100 I
>
>
> Blogs and organic groups at http://www.ccie.net
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html
Blogs and organic groups at http://www.ccie.net
This archive was generated by hypermail 2.1.4 : Mon Sep 01 2008 - 08:15:31 ART