In order to get our router to do anything truly useful, we’ll need to configure its interfaces. Recall that on a Cisco 2501, we have one Ethernet interface and two serial interfaces. We’ll start off by configuring these interfaces with IP addresses, and follow up by configuring IPX addresses.
Ethernet and serial interfaces are configured from the interface level of global configuration mode. In order to configure interface Ethernet 0, we’ll need to access that interface.
Enter configuration commands, one per line. End with CNTL/Z.
Our next step will be assigning interface Ethernet 0 an IP address. This couldn’t be easier – we’ll simply use the ip address command.
cisco2501(config-if)#ip address 192.168.1.46
% Incomplete command.
After entering the ip address command along with the address we want to configure, we’re faced with the incomplete command message. Obviously that means that we’ve forgotten something. Use the question mark to figure out what that something is.
cisco2501(config-if)#ip address 192.168.1.46 ?
A.B.C.D IP subnet mask
It’s now clear that we’re supposed to also add a subnet mask value following the IP address. In this case, we’ll use a mask of 255.255.255.0.
cisco2501(config-if)#ip address 192.168.1.46 255.255.255.0
The address is now set, but even if you tried to ping it from another system, you wouldn’t receive a reply. Why not? Because even though it has been configured, the interface is still not “turned on”. In order to make the interface active, you will need to enter the no shutdown command.
Assuming that you have a straight cable connecting the Ethernet 0 interface to a hub or switch, you should now be able to ping it from other systems.
Tip: As a best practice, issue the show interface command after configuring an interface to be sure that it is functioning correctly.
Configuring our router’s serial interfaces is really no different – access the serial interface that you wish to configure, and allocate an IP address and subnet mask using the same command. Remember that the no shutdown command will also need to be issued. The output below shows the configuration of IP address 192.168.2.1 on interface serial 0.
cisco2501(config)#int serial 0
cisco2501(config-if)#ip address 192.168.2.1 255.255.255.0
A variety of other properties can be configured for interfaces beyond their addresses and shutdown properties. To get a listing on the commands available, use the question mark from the router(config-if)# prompt.
It’s usually a good idea to also add a description to interfaces. For example, we could add a description to the serial 1 interface, mentioning that it connects the Toronto router to our Montreal location. This is also accomplished from the interface level of global configuration mode.
cisco2501(config-if)#description WAN link Toronto to Montreal
description WAN link Toronto to Montreal
ip address 192.168.2.1 255.255.255.0
I once again truncated the output from the show run command, limiting it to the pertinent information about the serial 0 interface. Notice the description is now included in the interface section. This provides a quick and easy way to reference what a given interface connects to.