Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements
Webcast-Catalyst9k
New Member

Some "| include" in one command

Hello, I am managing a Cisco 2801 router and I want to view some information from a command. For example:

###start code###

router#show ip sla monitor statistics

Round trip time (RTT) Index 1

Latest RTT: 44 ms

Latest operation start time: 12:41:18.244 MET Thu Mar 19 2009

Latest operation return code: OK

RTT Values

Number Of RTT: 500

RTT Min/Avg/Max: 43/44/48 ms

Latency one-way time milliseconds

Number of one-way Samples: 500

Source to Destination one way Min/Avg/Max: 21/22/26 ms

Destination to Source one way Min/Avg/Max: 21/21/22 ms

Jitter time milliseconds

Number of SD Jitter Samples: 499

Number of DS Jitter Samples: 499

Source to Destination Jitter Min/Avg/Max: 0/1/3 ms

Destination to Source Jitter Min/Avg/Max: 0/1/1 ms

Packet Loss Values

Loss Source to Destination: 0 Loss Destination to Source: 0

Out Of Sequence: 0 Tail Drop: 0 Packet Late Arrival: 0

Voice Score Values

Calculated Planning Impairment Factor (ICPIF): 0

Mean Opinion Score (MOS): 0

Number of successes: 12

Number of failures: 0

Operation time to live: Forever

###finish code###

I just want to view theese four lines:

Latency one-way time milliseconds

Number of one-way Samples: 500

Source to Destination one way Min/Avg/Max: 21/22/26 ms

Destination to Source one way Min/Avg/Max: 21/21/22 ms

With "| include something" I can select just one line, but I want to view the four lines.

Is any way to do that?

Thanks for all, regards.

Josu Lazkano.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Some "| include" in one command

I would say the following should work for you:

sh ip sla monitor statistics | include way

And to do the same with multiple string search:

sh ip sla monitor statistics | include Latency|of one-way|Destination one|Source one

NOTE: no spaces between the '|' and the different search strings

(i tested this with IOS Version 12.2(18)SXF8)

2 REPLIES

Re: Some "| include" in one command

I would say the following should work for you:

sh ip sla monitor statistics | include way

And to do the same with multiple string search:

sh ip sla monitor statistics | include Latency|of one-way|Destination one|Source one

NOTE: no spaces between the '|' and the different search strings

(i tested this with IOS Version 12.2(18)SXF8)

New Member

Re: Some "| include" in one command

Thank you very much!

This is exactly what I was looking for.

Thanks again.

106
Views
0
Helpful
2
Replies
CreatePlease to create content