RE: OT: filtering Show Outputs

From: Tyson Scott <tscott_at_ipexpert.com>
Date: Tue, 31 Aug 2010 10:59:05 -0400

I will challenge you to find it in the Cisco Documentation. You should know
where it is so you can use it in the lab.

 

Regards,

 

Tyson Scott - CCIE #13513 R&S, Security, and SP

Managing Partner / Sr. Instructor - IPexpert, Inc.

Mailto: <mailto:tscott_at_ipexpert.com> tscott_at_ipexpert.com

Telephone: +1.810.326.1444, ext. 208

Live Assistance, Please visit: <http://www.ipexpert.com/chat>
www.ipexpert.com/chat

eFax: +1.810.454.0130

 

IPexpert is a premier provider of Self-Study Workbooks, Video on Demand,
Audio Tools, Online Hardware Rental and Classroom Training for the Cisco
CCIE (R&S, Voice, Security & Service Provider) certification(s) with
training locations throughout the United States, Europe, South Asia and
Australia. Be sure to visit our online communities at
<http://www.ipexpert.com/communities> www.ipexpert.com/communities and our
public website at <http://www.ipexpert.com/> www.ipexpert.com

 

From: olumayokun fowowe [mailto:olumayokun_at_gmail.com]
Sent: Tuesday, August 31, 2010 5:43 AM
To: Tyson Scott
Cc: Tolulope Ogunsina; Yemi Oshunkoya; ccielab_at_groupstudy.com
Subject: Re: OT: filtering Show Outputs

 

Hello Tysson,

Thanks alot. It worked for up to the first 9 listings. I tried modifying the
command for listings beyond the first 9 then the output became different. I
guess I should now be talking about knowing more on filters. I will
appreciate if you can mail me the url for the EEM configuration guide.

Thank you.

On Tue, Aug 31, 2010 at 1:46 AM, Tyson Scott <tscott_at_ipexpert.com> wrote:

The following comes right from the EEM configuration guide. Just a slight
modification on the show command

event manager applet snmpcpuge75
event snmp oid 1.3.6.1.4.1.9.9.109.1.1.1.1.3.1 get-type exact entry-op ge
entry-val 75
poll-interval 10
action 1.0 cli command "enable"
action 2.0 cli command "show process cpu | incl ^ [1-5]"
action 3.0 mail server "192.168.1.146" to "engineer_at_cisco.com" from
"devtest_at_cisco.com"
subject "B25 PBX Alert" body "$_cli_result"

the incl ^ [1-5] will make sure you only get the first 5 process listings.

For your memory question it would be very similar but you would have to look
up the SNMP OID For memory usage and the command would be as follows.

show process memory | incl ^ [0-2]

make sure you have the ^ (carat) and three spaces so you can capture the PID
of the first 5 processes.

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

Tolulope Ogunsina
Sent: Monday, August 30, 2010 11:40 AM
To: olumayokun fowowe; Yemi Oshunkoya
Cc: ccielab_at_groupstudy.com
Subject: Re: OT: filtering Show Outputs

Try Tcl/EEM.

Best Regards, Tolulope Ogunsina, CCIE x2 (R&S|Sec)

-----Original Message-----
From: olumayokun fowowe <olumayokun_at_gmail.com>
Sender: nobody_at_groupstudy.com
Date: Mon, 30 Aug 2010 16:37:45
To: Yemi Oshunkoya<yzmar4real_at_hotmail.com>
Reply-To: olumayokun fowowe <olumayokun_at_gmail.com>
Cc: <ccielab_at_groupstudy.com>
Subject: Re: OT: filtering Show Outputs

Hello all,

Please let me make myself a bit clearer:

suppose i issue the command "show processes memory" and I want to filter the
output to show the first 5 lines of the output. How do I filter such.

Thanks,

On Mon, Aug 30, 2010 at 4:33 PM, Yemi Oshunkoya
<yzmar4real_at_hotmail.com>wrote:

> it generally depends on what you want to see.
>
> i usually "pipe" it
>
> show run | sec router
> show run | include ip route
>
> e.t.c
>
> HTH
>
> > Date: Mon, 30 Aug 2010 16:30:05 +0100
> > Subject: OT: filtering Show Outputs
> > From: olumayokun_at_gmail.com
> > To: ccielab_at_groupstudy.com
> >
> > Hello Guys,
> >
> > How can i filter my show commands to feature certain number of lines in
> > cisco devices.
> >
> > Thank you.
> >
> > --
> > Olumayokun Fowowe
> >
> >
> > 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
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html
>
>
>
>
>
>
>
>

--
Olumayokun Fowowe
Blogs and organic groups at http://www.ccie.net
Received on Tue Aug 31 2010 - 10:59:05 ART

This archive was generated by hypermail 2.2.0 : Wed Sep 01 2010 - 11:20:53 ART