In the Internet world, the router's job is to take IP packets and move them from one interface to another. This is the core functionality of the router, though it may also do other things as well along the way (mostly relating to updating the "forwarding" or "routing" tables that dictate where the packets go).


While a route can have many more attributes, the most fundamental three attributes of all IP routes in a Cisco are:

    (1) The starting IP address.
    (2) The length of the route (specified by the netmask).
    (3) The destination IP or Interface of the route.

Basically, a route says "for packets destined to IP addresses in the range specified, send them to this interface or IP address."


For every packet that comes in, the router looks at the destination IP address and tries to find the most specific route that matches it. The router then sends the packet out the interface specified in that most specific route.

The most specific route is the one that covers the least number of IP addresses. For example, a host route covers only one IP address and is an example of the most specific IP route possible. A less specific IP route is a Class C-sized route of 256 IP addresses. The least specific (most general) route is the default route, which covers any route not specifically covered by a more specific route.

This describes the average host on the average network on the Internet: any packet destined to itself will pick off with the host route; any packet destined to the local LAN will be sent out the LAN because of the Class C-sized route; and any packet destined to the Internet is not covered by either of those routes, so it is sent out to the router using the default route. The "most specific route wins" rule is one of the most fundamental rules of IP routing.

Routing based on destination IP address is not the only way to route (see policy routing in the Cisco documentation for methods of routing based on source-interface or source-IP rather than on destination IP), but it is fairly fundamental to Internet routing.


Each router has multiple interfaces. The most common interfaces you'll deal with are Ethernet and serial interfaces, though before long you'll want to know how to configure the Console and Aux normal (asynchronous) serial interfaces, and you may want to send routes to the Null0 or Loopback virtual interfaces. High-end routers (which we'll cover eventually) have HSSI (for T-3s); ATM; Fast Ethernet; and other, more exotic, interfaces. Each interface usually has one or more IP addresses.

Serial interfaces on a Cisco router are actually synchronous interfaces generally used to run leased-line CSU/DSUs. Normally, you'll run them with external clocking (unless you're connecting two routers together). In this mode, the router has no preset idea of how fast each port will be - as long as it's not a low-speed serial port, every Cisco synchronous serial port should run speeds up to T-1 or E-1.


On fixed-configuration Ciscos such as the 2500 series, each interface is numbered simply - for example, Ethernet0, Ethernet1 (if you have a 2514, which has two Ethernet ports), Serial0, and Serial1. Every Cisco has a Console and most have Aux ports.

On larger Ciscos (except for the AGS, which is an older "large" Cisco), to specify an interface you need to know the slot number of the Interface card. For example, Ethernet0/0 and Ethernet0/1 are the first and second Ethernet interfaces on the Ethernet interface board in Slot 0. Serial4/0, Serial4/1, Serial4/2, Serial4/3, Serial4/4, Serial4/5, Serial4/6, and Serial4/7 are the 8 serial interfaces on the serial board in slot 4. Routers such as the 7206, 7000, 7010, 7505, 7507, and 7509 use this nomenclature.

When referring to interfaces, you can abbreviate as much as is possible without causing ambiguity - for example, e0, s0, and s1 instead of Ethernet0, Serial0, and Serial1.


Ciscos can have many different routing tables in RAM - especially if you're using active internal and external routing protocols - but the goal of the routing protocols is to actually populate the one actual IP routing table on which all packet-routing decisions are based. The technical term for this table in a Cisco is "the RIB" (routing information base), but it's commonly referred to as just "the IP routing table."

There are various ways to modify how competing routes get inserted into the RIB, but if unmodified, the order of preference is:

    (1) Connected routes - most fundamental because they're associated with interfaces.
    (2) Static routes - next most fundamental because they're used as "glue" and to "kludge around" routing problems.
    (3) Internet routing protocols - OSPF, RIP, IS-IS (because you should trust yourself first...).
    (4) External routing protocols - BGP4.

"Competing routes" are routes of equal specificity that are present in multiple routing tables (from multiple sources).


It may seem simple and obvious, but not all routers implement a very critical function. Ciscos will delete routes from the RIB if the interface associated with the route is down. This allows the Cisco to have backup routes quite easily. When you get fairly into routing, you'll understand why this is a critical feature.

What this means is that if you unplug the Ethernet and serial interfaces from a simply configured 2501, a "sho ip route" will show no routes, since there are no interfaces "up" to attach routes.


The most fundamental routes on the router are those associated with the interfaces themselves. If e0 (aka Ethernet0) has an IP address of 10.20. 20.1 and the netmask is (the size of a Class C - also called a /24), the route "10.20 .20.0/24" gets installed as a connected route, pointed out (e0). Any packets destined for through will be sent out e0 (if there are no more specific routes inside of


The next most fundamental type of route is that static route. These are routes that you insert with the "ip route" command. The "default route" is generally inserted as a static route, for example:

ip route Serial1

Most smaller networks will be entirely "static routed" - the only routes on the routers will be connected or static routes.

Another quick note on static routes: adding a metric at the end of the ip route statement can change the preference of the route. The most common use of this is to insert a backup route. For example:

ip route Serial1
ip route Serial0 10

will cause the route pointing to Serial0 to stay unused, but to be inserted quickly if the preferred Serial1 route goes away (because it was deleted by hand or because the Serial1 interface went away).


Dynamic routing protocols cause one router to advertise routes to another router. The routes being advertised always start out as static or connected routes somewhere, though. Eventually, we'll talk about OSPF, RIPv2, and IS-IS, which are interior gateway protocols (IGPs). You need to use an IGP if:

  • You want to have a network that goes around in a redundant ring, and want it to "fail over" automagically or
  • You want to have dial-up users dial into multiple terminal servers. The terminal servers have to dynamically tell the routers who is connected at any time, or the routers won't be able to find them.

We've talked about BGP in earlier issues. BGP is a protocol used to dynamically advertise your routes to other networks, and to take dynamic route advertisements from them.


This month, we'll end with a walk-through of the Cisco initial setup dialog - what you get if you turn on a new, unconfigured Cisco.

For our example, we'll use a typical, small ISP configuring its first router, which has:

  •  An Ethernet address of, mask, on the Ethernet0 port
  • A serial address of, mask, on the Serial0 port

The only thing that can't be done in the initial configuration dialog is the default-route installation; we'll go over that below.

Also, we'll use:

    (1) "internet-gw1" as the router's host name. This is not the Internet-visible hostname; it's just something that the router shows in command prompts.
    (2) "letmein1" as the enable secret and enable password. It will complain but will let you set the same password for both parameters.
    (3) "letmein2" as the virtual terminal password.

Would you like to enter the initial
	configuration dialog? [yes]
First, would you like to see the current
	interface summary? [yes]
Enter host name [Router]: ltbgtinternet-gw1lt/bgt
Enter enable secret: ltbgtletmein1lt/bgt
Enter enable password: ltbgtletmein1lt/bgt
Enter virtual terminal password: ltbgtletmein2lt/bgt
Configure SNMP Network Management? [yes]: ltbgtnolt/bgt
Configure IP? [yes]: ltbgtyeslt/bgt
	Configure IGRP routing? [yes]: ltbgtnolt/bgt
	Configure RIP routing? [no]: ltbgtnolt/bgt
	ltPossibly other IP routing protocol questions which you answer no togt
Configuring interface Ethernet0:
	Is this interface in use? [yes]: ltbgtyeslt/bgt
	Configure IP for this interface? [yes]: ltbgtyeslt/bgt
	IP address for this interface: ltbgt207.106.1.1lt/bgt
	Number of bits in subnet feld [0]: ltbgt0lt/bgt
Configuring interface Serial0:
	Is this interface in use? [yes]: ltbgtyeslt/bgt
	Configure IP for this interface? [yes]: ltbgtyeslt/bgt
	IP address for this interface: ltbgt207.106.127.45lt/bgt
	Number of bits in subnet feld [0]: ltbgt6lt/bgt
Configuring interface Serial1:
	Is this interface in use? [yes]: ltbgtnolt/bgt 

If you are asked any other yes/no questions, answer no. Then you are shown an initial configuration based on the dialog above.

Building configuration... [yes/no]:

Then the router will write and load that configuration. It will be done and ready to use in a few minutes.

When it's done, enter:

ltenter the enable password when askedgt
conf term
ip route Serial0

To finish the configuration.

Once that's done, plug in the Ethernet port and see if you can ping it. If you can, then Telnet into it and start looking at the interfaces (type "sho int Serial0").

If Serial0 is up and the line protocol on Serial0 is up, see if you can ping to the outside world (say, to, as an example).

If you can, you're done - and if not, call your ISP and ask them to walk you through things. And make sure they've turned up and configured their end of the circuit.

Copyright 1998 Mecklermedia Corporation.
All Rights Reserved. Legal Notices.
About Mecklermedia Corp.

Colorado Offices
13949 W Colfax Ave Suite 250, Golden, CO 80401
Voice: 303-235-9510; Fax: 303-235-9502

Fable Of Contents