22.10.2013 Views

7.8.1.0 - Force10 Networks

7.8.1.0 - Force10 Networks

7.8.1.0 - Force10 Networks

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Filtering show Command Outputs<br />

Filter the output of a show command to display specific information by adding | [except | find | grep |<br />

no-more | save] specified_text after the command. The variable specified_text is the text for which you are<br />

filtering, and it is case sensitive, with one exception:<br />

Starting with FTOS <strong>7.8.1.0</strong>, the grep option offers an ignore-case sub-option that makes the search<br />

case-insensitive. For example, the commands:<br />

• show run | grep Ethernet returns a search result with instances containing a capitalized<br />

“Ethernet”, such as interface GigabitEthernet 0/0.<br />

• show run | grep ethernet would not return that search result because it only searches for<br />

instances containing a non-capitalized “ethernet”.<br />

Executing the command show run | grep Ethernet ignore-case would return instances<br />

containing both “Ethernet” and “ethernet”.<br />

• grep displays only the lines containing specified text. Figure 9 shows this command used in<br />

combination with the command show linecard all.<br />

Figure 9 Filtering Command Outputs with the grep Command<br />

<strong>Force10</strong>(conf)#do show linecard all | grep 0<br />

0 not present<br />

Note: FTOS accepts a space or no space before and after the pipe. To filter on a phrase with spaces,<br />

underscores, or ranges, enclose the phrase with double quotation marks.<br />

• except displays text that does not match the specified text. Figure 10 shows this command used in<br />

combination with the command show linecard all.<br />

Figure 10 Filtering Command Outputs with the except Command<br />

<strong>Force10</strong>#show linecard all | except 0<br />

-- Line cards --<br />

Slot Status NxtBoot ReqTyp CurTyp Version Ports<br />

---------------------------------------------------------------------------<br />

2 not present<br />

3 not present<br />

4 not present<br />

5 not present<br />

6 not present<br />

• find displays the output of the show command beginning from the first occurrence of specified text<br />

Figure 11 shows this command used in combination with the command show linecard all.<br />

FTOS Configuration Guide, version <strong>7.8.1.0</strong> 41

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!