Sunday, May 1, 2011

Configuring static routes

Configuring static routes 
6.1.3
This page lists the steps used to configure static routes and gives an example of a simple network for which static routes might be configured.
Use the following steps to configure static routes:
Step 1 Determine all desired prefixes, masks, and addresses. The address can be either a local interface or a next hop address that leads to the desired destination.
Step 2 Enter global configuration mode.
Step 3 Type the ip route command with a prefix and mask followed by the corresponding address from Step 1. The administrative distance is optional.
Step 4 Repeat Step 3 for all the destination networks that were defined in Step 1.
Step 5 Exit global configuration mode.
Step 6 Use the copy running-config startup-config command to save the active configuration to NVRAM.
The example network is a simple three-router configuration. Hoboken must be configured so that it can reach the 172.16.1.0 network and the 172.16.5.0 network. Both of these networks have a subnet mask of 255.255.255.0.
Packets that have a destination network of 172.16.1.0 need to be routed to Sterling and packets that have a destination address of 172.16.5.0 need to be routed to Waycross. Static routes can be configured to accomplish this task.
Both static routes will first be configured to use a local interface as the gateway to the destination networks. Since the administrative distance was not specified, it will default to 1 when the route is installed in the routing table.
The same two static routes can also be configured with a next-hop address as their gateway. The first route to the 172.16.1.0 network has a gateway of 172.16.2.1. The second route to the 172.16.5.0 network has a gateway of 172.16.4.2. Since the administrative distance was not specified, it defaults to 1.
The Lab Activity will help students learn how to configure static routes.
The next page will explain how default routes are configured.

Static route operation

Static route operation 
6.1.2
This page will explain how static routes operate and how they are created.
Static route operations can be divided into these three parts:
  • Network administrator configures the route
  • Router installs the route in the routing table
  • The static route is used to route packets.
An administrator must use the ip route command to manually configure a static route. The correct syntax for the ip route command is shown in Figure .
In Figures and , the network administrator of the Hoboken router needs to configure a static route to the 172.16.1.0/24 and 172.16.5.0/24 networks on the other routers. The administrator could enter either of two commands to accomplish this objective. The method in Figure specifies the outgoing interface. The method in Figure specifies the next-hop IP address of the adjacent router. Either of the commands will install a static route in the routing table of Hoboken.
The administrative distance is an optional parameter that indicates the reliability of a route. A lower value for the administrative distance indicates a more reliable route. A route with a lower administrative distance will be installed before a similar route with a higher administrative distance. The default administrative distance when using a static route is 1. In the routing table, it will show the static route with the outgoing interface option as being directly connected. This is sometimes confusing, since a true directly connected route has an administrative distance of 0. To verify the administrative distance of a particular route, use the show ip routeaddress command, where the ip address of the particular route is inserted for the address option. If an administrative distance other than the default is desired, a value between 0 and 255 is entered after the next-hop or outgoing interface as follows:
waycross(config)#ip route 172.16.3.0 255.255.255.0 172.16.4.1 130
If the router cannot reach the outgoing interface that is being used in a route, the route will not be installed in the routing table. This means if that interface is down, the route will not be placed in the routing table.
Sometimes static routes are used for backup purposes. A static route can be configured on a router that will only be used when the dynamically learned route has failed. To use a static route as a backup, set a higher administrative distance than the dynamic routing protocol.
The Lab Activities will show students how static routes are created and used to troubleshoot networks.
The next page will teach students how to configure static routes.

Introduction to routing / Introduction to routing

Introduction to Static Routing 
Introduction to routing 
6.1.1 
This page will describe routing and explain the differences between static and dynamic routing.
Routing is the process that a router uses to forward packets toward the destination network. A router makes decisions based upon the destination IP address of a packet. All devices along the way use the destination IP address to send the packet in the right direction to reach its destination. To make the correct decisions, routers must learn how to reach remote networks. When routers use dynamic routing, this information is learned from other routers. When static routing is used, a network administrator configures information about remote networks manually.
Since static routes are configured manually, network administrators must add and delete static routes to reflect any network topology changes. In a large network, the manual maintenance of routing tables could require a lot of administrative time. On small networks with few possible changes, static routes require very little maintenance. Static routing is not as scalable as dynamic routing because of the extra administrative requirements. Even in large networks, static routes that are intended to accomplish a specific purpose are often configured in conjunction with a dynamic routing protocol.
The next page will explain static route operations.