2.14 Routing Concepts

Basic Router Configuration Review

Full Router Configuration Example

A Full Basic Router Configuration Complete Example
Router> enable 
Router# configure terminal 
Enter configuration commands, one per line. End with CNTL/Z. 
Router(config)# hostname R1 
R1(config)# enable secret P455W0RD 
R1(config)# line console 0 
R1(config-line)# logging synchronous 
R1(config-line)# password CISCO 
R1(config-line)# login 
R1(config-line)# exit 
R1(config)# line vty 0 15 
R1(config-line)# password CISCO 
R1(config-line)# login 
R1(config-line)# transport input ssh 
R1(config-line)# exit 
R1(config)# service password-encryption 
R1(config)# banner motd #Authorized Personnel Only!#
R1(config)# ipv6 unicast-routing
R1(config)# interface gigabitethernet 0/0/0
R1(config-if)# description Link to LAN1
R1(config-if)# ip address 192.168.1.1 255.255.255.0
R1(config-if)# ipv6 address 2001:db8:acad:1::1/64
R1(config-if)# ipv6 address fe80::1:1 link-local
R1(config-if)# no shutdown 
R1(config-if)# exit 
R1(config)# interface gigabitethernet 0/0/1
R1(config-if)# description Link to LAN2 
R1(config-if)# ip address 192.168.2.1 255.255.255.0 
R1(config-if)# ipv6 address 2001:db8:acad:2::1/64
R1(config-if)# ipv6 address fe80::1:2 link-local
R1(config-if)# no shutdown 
R1(config-if)# exit 
R1(config)# interface serial 0/1/1
R1(config-if)# description Link to R2
R1(config-if)# ip address 192.168.3.1 255.255.255.0
R1(config-if)# ipv6 address 2001:db8:acad:3::1/64
R1(config-if)# ipv6 address fe80::1:3 link-local 
R1(config-if)# no shutdown
R1(config-if)# exit
R1# copy running-config startup-config 
Destination filename [startup-config]? 
Building configuration... 
[OK] 
R1#

Verification Commands

Some of the most used verification commands:

S1show ip interface brief
S1show running-config interface [interface]
S1show interfaces
S1show ip interface
S1show ip route
S1ping [IPv4/IPv6 Address]

[NOTE] For IPv6 versions of these commands, simply replace “ip” with “ipv6“.

Filter Command Output

A really useful feature which greatly improves user experience when using the CLI (Command Line Interface) is the ability to filter the “show” output.

Filtering commands can be used to display partial sections of output. To use filtering simply enter a pipe (|) after the desired show command and then enter a filtering parameter and a filtering expression

There are 4 filtering parameters that can be used after the pipe character:

section
This will display an entire section that starts with the filtering expression specified
include
This will include all output lines that match the filtering expression specified
exclude
This will exclude all output lines that match the filtering expression specified
begin
This will display all output lines starting from a specific point which matches the filtering expression specified

[NOTE] Such filters work with ANY show command.