Fortinet white logo
Fortinet white logo

Pipe options for displaying content

Pipe options for displaying content

The options in the table below are available for many commands that display content, such as “get”, “show” and “diagnose” commands.

Grep usage:

show system interface | grep [-cinv] [-A=<trailingCount>]
                                     [-B=<leadingCount>]
                                     [-C=<outputContextCount>] <pattern>

Available options:

<pattern>

Pattern to grep for

-A=<trailingCount>

Print NUM lines of trailing context

-B=<leadingCount>

Print NUM lines of leading context

-c

Display only count of matching lines

-C=<outputContextCount>

Print NUM lines of output context

-i

Ignore case

-n

Print line number with output lines

-v

Display non-matching lines

Less usage:

show system interface | less

Pipe options for displaying content

Pipe options for displaying content

The options in the table below are available for many commands that display content, such as “get”, “show” and “diagnose” commands.

Grep usage:

show system interface | grep [-cinv] [-A=<trailingCount>]
                                     [-B=<leadingCount>]
                                     [-C=<outputContextCount>] <pattern>

Available options:

<pattern>

Pattern to grep for

-A=<trailingCount>

Print NUM lines of trailing context

-B=<leadingCount>

Print NUM lines of leading context

-c

Display only count of matching lines

-C=<outputContextCount>

Print NUM lines of output context

-i

Ignore case

-n

Print line number with output lines

-v

Display non-matching lines

Less usage:

show system interface | less