Skip to main content
  • Place orders quickly and easily
  • View orders and track your shipping status
  • Enjoy members-only rewards and discounts
  • Create and access a list of your products
  • Manage your Dell EMC sites, products, and product-level contacts using Company Administration.

Dell Command Line Reference Guide for the S4048–ON System 9.14.2.8

Filtering show Commands

You can filter commands using the show command to find specific information, display certain information only, or begin the command output at the first instance of a regular expression or phrase.

Execute a show command and a pipe ( | ), and one of the following parameters and a regular expression to show output that either excludes or includes the specified parameters.

NOTE The Dell EMC Networking OS accepts a space before or after the pipe, no space before or after the pipe, or any combination. For example: command | grep gigabit |except regular-expression | find regular-expression.
except
Displays only the text that does not match the pattern (or regular expression).
find
Searches for the first occurrence of a pattern.
grep
Displays text that matches a pattern.

The grep command option has an ignore-case suboption that makes the search case-insensitive. For example, the commands:

show run | grep Ethernet
Returns a search result with instances containing a capitalized Ethernet, such as interface TenGigabitEthernet 1/1.
show run | grep ethernet
Does not return the previous search result because it only searches for instances containing a noncapitalized ethernet.
show run | grep Ethernet ignore-case
Returns instances containing both Ethernet and ethernet.
no-more
Does not paginate the display output.
save
Copies the output to a file for future use.

Displaying All Output

Use the no-more option after the pipe to display all output at once — not one screen at a time. This operation is similar to terminal length screen-length except that the no-more option affects the output of just the specified command. For example: show running-config|no-more.

Filtering the Command Output Multiple Times

You can filter a single command output multiple times. To filter a command output multiple times, place the save option as the last filter. For example: command | grep regular-expression | except regular-expression | grep other-regular-expression | find regular-expression | no-more | save.


Rate this content

Accurate
Useful
Easy to understand
Was this article helpful?
0/3000 characters
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please select whether the article was helpful or not.
  Comments cannot contain these special characters: <>()\