RE: Regular Expressions Eigrp top all links.

From: Tyson Scott <tscott_at_ipexpert.com>
Date: Thu, 13 Jan 2011 09:18:06 -0500

Put it onto a UNIX/Linux machine and type the following command

tyson_at_atr-lnx:~> grep -B 1 "t0/1" test
P 10.10.10.10/32, 1 successors, FD is 156160
        via 10.1.1.10 (156160/128256), FastEthernet0/1

--
P 12.12.12.12/32, 1 successors, FD is 156160
        via 10.1.1.12 (156160/128256), FastEthernet0/1
--
P 10.1.1.0/24, 1 successors, FD is 28160
        via Connected, FastEthernet0/1
tyson_at_atr-lnx:~>
Yours of course would be grep -B 1 "Tunnel2" <filename>
the pipe functions on the router simply don't have enough options to my
knowledge.  You could write a TCL script to parse the data and print it for
you but the above is the more simple approach.
Regards,
 
Tyson Scott - CCIE #13513 R&S, Security, and SP
Managing Partner / Sr. Instructor - IPexpert, Inc.
Mailto: tscott_at_ipexpert.com
-----Original Message-----
From: nobody_at_groupstudy.com [mailto:nobody_at_groupstudy.com] On Behalf Of
Scott Morris
Sent: Thursday, January 13, 2011 8:50 AM
To: ccielab_at_groupstudy.com
Subject: Re: Regular Expressions Eigrp top all links.
It'll depend on the formatting of the show output, but you can try using
"section" instead of "include" and get better results.
HTH,
 
*Scott Morris*, CCIE/x4/ (R&S/ISP-Dial/Security/Service Provider) #4713,
CCDE #2009::D, JNCIE-M #153, JNCIS-ER, CISSP, et al.
CCSI #21903, JNCI-M, JNCI-ER
swm_at_emanon.com
Knowledge is power.
Power corrupts.
Study hard and be Eeeeviiiil......
On 1/13/11 8:02 AM, me you wrote:
> I would like to use regular expressions to view a line from EIGRP top all
> links. I am using the command "Show ip eigrp top all | i Tunnel2"  I get a
> single line result for all the ip address learned from Tunnel2; however, I
> want to see the line above with the IP address learned via tunnel 2. How
can
> I use regular expressions or someother command to view the ip address
> and eigrp topo all-links  learned from tunnel 2
>
> Thank you
> Rob.
>
>
> 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
Received on Thu Jan 13 2011 - 09:18:06 ART

This archive was generated by hypermail 2.2.0 : Tue Feb 01 2011 - 07:39:17 ART