Mike's PBX Cookbook

Show Configuration

View the configuration files with the showcommand, followed by filename.
For example, to view the running configuration, enter: show running-config

To retain the running configuration after a power cycle, copy it from RAM to NVRAM.
Use the copy command, followed by the source and destination (from/to) filenames:

eg: copy running-config startup-config

Commands:

Commonly used show commands.

CommandDescription
show running-configDisplays the running configuration. You can also use filters, eg: show running-config interface GigabitEthernet0/1 to display only the interface GigabitEthernet0/1 running configuration.
show startup-configDisplays the startup configuration stored in NVRAM.
configure terminalEnters the Global Configuration Mode, in order to change the the currently running-config (stored in RAM).
copy running-config startup-configSaves the running configuration to startup-config file in NVRAM.
copy startup-config running-configStartup configuration from NVRAM is merged into the running configuration.
copy running-config tftpCopies the running configuration (in RAM) to a TFTP server, prompts for TFTP server IP address.
erase startup-configDeletes the saved startup-config file in NVRAM.
reloadReboot the switch. The running configuration is lost, and startup configuration is loaded at restart.

Filters:

Use filtering to display only specific parts of show outputs.

FilterDescription
beginShows all output lines, starting with the line that matches the filtering expression
excludeExcludes all output lines that match the filtering expression
includeIncludes all output lines that match the filtering expression
sectionShows the entire section that starts with the filtering expression

Paging:

When you execute the show running-config (show run) command, the output is paged one screen at a time. If you want to paste the output into a text editor, this may be impractical. The default screen length is 24 lines, which can be verified with:show terminal.
To disable paging mode, enter:terminal length 0 (term len 0). To restore normal paging mode, enter:term no len 0 or term len 24.

Examples:

Filter outputs by using the pipe (|) character after show.

➤ Show config with begin option:

R1# show running-config | begin interface
interface Loopback0
 ip address 10.10.10.1 255.255.255.0
!
interface Ethernet0/0
 description Link to SW2
 ip address 10.10.11.1 255.255.255.0
!
interface Ethernet0/1
 no ip address
 shutdown
!

➤ To focus on a config section:

R1# show running-config | section interface
interface Loopback0
 ip address 10.10.10.1 255.255.255.0
interface Ethernet0/0
 description Link to SW2
 ip address 10.10.11.1 255.255.255.0
interface Ethernet0/1
 no ip address
 shutdown
interface Ethernet0/2
 no ip address
 shutdown

➤ Output with the include option:

R1# show running-config | include interface
interface Loopback0
interface Ethernet0/0
interface Ethernet0/1
interface Ethernet0/2
interface Ethernet0/3
interface Serial1/0
interface Serial1/1
interface Serial1/2
interface Serial1/3

➤ To exclude lines starting with ! (comments):

R1# show running-config | exclude !
Building configuration...
 
Current configuration : 1223 bytes
version 15.2
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
hostname R1
boot-start-marker