Interface configuration is one of the most important router configurations, because without
interfaces, a router is pretty much a completely useless object. Plus, interface configurations
must be totally precise to enable communication with other devices. Network layer addresses,
media type, bandwidth, and other administrator commands are all used to configure an interface.
Table 1.10 shows the commands.
TABLE 1 . 1 0 Router Interface Commands
Command Meaning
Todd(config)#interface fastethernet
slot/port
Enters interface configuration mode from global
configuration mode.
Todd(config)#interface serial slot/port Same as the previous command, except for serial
interface 0/0/0 rather than Fast Ethernet interface.
Todd(config-if)#shutdown Shuts down an interface.
Todd(config-if)#no shutdown Enables an interface that is shut down.
Todd(config-if)#ip address address
mask
Configures an interface with an IP address and a
subnet mask.
Todd(config-if)#ip address address
mask secondary
Adds a secondary IP address to an interface.
Todd(config-if)#description
description
Adds a description to an interface.
Todd(config-if)#clock rate rate Sets the clock rate of a serial interface in bits per
second.
Todd(config-if)#bandwidth rate Sets the bandwidth of an interface in kilobits per
second.
Todd#show interface interface Displays the status and configuration of the Fast
Ethernet interface.
Todd#clear counters interface Clears the display counters on the serial interface.
Todd#sh ip interface interface Displays the layer-3 properties of an interface.
Todd#sh ip int brief Displays the IP interfaces in a summarized table.
This is one of the most useful show commands!
Let’s take a look at setting both an IP address and a secondary IP address on an interface,
and then we’ll verify the configuration:
Todd(config)#interface fastEthernet 0/0
Todd(config)#interface serial 0/0/0
Todd(config-if)#shutdown
Jul 30 15:31:23.542: %LINK-5-CHANGED: Interface Serial0/0/0, changed state to
administratively down
Jul 30 15:31:24.542: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0/
0, changed state to down
Todd(config-if)#no shutdown
Jul 30 15:31:27.566: %LINK-3-UPDOWN: Interface Serial0/0/0, changed state to up
Jul 30 15:31:28.566: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0/0,
changed state to up
Todd(config-if)#ip address 172.16.10.1 255.255.255.0
Todd(config-if)#ip address 172.16.20.1 255.255.255.0 ?
secondary Make this IP address a secondary address
Todd(config-if)#ip address 172.16.20.1 255.255.255.0 secondary
Todd(config-if)#description Serial link to Miami
Todd(config-if)#clock rate 1000000
Todd(config-if)#bandwidth 1000
Todd(config-if)#exit
Todd(config)#exit
Todd#show interface s0/0/0
Serial0/0/0 is up, line protocol is up
Hardware is GT96K Serial
Description: Serial link to Miami
Internet address is 172.16.10.1/24
MTU 1500 bytes, BW 1000 Kbit, DLY 20000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation HDLC, loopback not set
Keepalive set (10 sec)
Last input 00:00:04, output 00:00:08, output hang never
Last clearing of "show interface" counters 2d05h
Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
Queueing strategy: fifo
Output queue: 0/40 (size/max)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
34632 packets input, 2479012 bytes, 0 no buffer
Received 34031 broadcasts, 0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
34372 packets output, 2303104 bytes, 0 underruns
0 output errors, 0 collisions, 5 interface resets
0 output buffer failures, 0 output buffers swapped out
112 carrier transitions
DCD=up DSR=up DTR=up RTS=up CTS=up
Todd#clear counters s0/0/0
Clear "show interface" counters on this interface [confirm][enter]
Jul 30 15:39:02.818: %CLEAR-5-COUNTERS: Clear counter on interface Serial0/0/0
by console
Todd#sh ip interface s0/0/0
Serial0/0/0 is up, line protocol is up
Internet address is 172.16.10.1/24
Broadcast address is 255.255.255.255
Address determined by setup command
MTU is 1500 bytes
Helper address is not set
Directed broadcast forwarding is disabled
Secondary address 172.16.20.1/24
Secondary address 172.16.30.1/24
Outgoing access list is not set
Inbound access list is not set
Proxy ARP is enabled
Local Proxy ARP is disabled
Security level is default
Split horizon is enabled
ICMP redirects are always sent
ICMP unreachables are always sent
ICMP mask replies are never sent
IP fast switching is enabled
IP fast switching on the same interface is enabled
IP Flow switching is disabled
IP CEF switching is enabled
IP CEF Fast switching turbo vector
[output cut]
Todd#sh ip int brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 192.168.21.1 YES manual up up
FastEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 172.16.10.1 YES manual up up
Serial0/0/1 unassigned YES unset administratively down down
Todd#
Viewing, Saving, and Erasing Configurations
Once you have gone to all the work of creating a configuration, you will need to know
how to save it, and maybe even delete it. Table 1.11 shows the commands used to manipulate
configurations.