Table Of Contents
Reliable Static Routing Backup Using Object Tracking
Prerequisites for Reliable Static Routing Backup Using Object Tracking
Restrictions for Reliable Static Routing Backup Using Object Tracking
Information About Reliable Static Routing Backup Using Object Tracking
Reliable Static Routing Backup Using Object Tracking
Benefits of Reliable Static Routing Backup Using Object Tracking
How to Configure Reliable Static Routing Backup Using Object Tracking
Configuring the Primary Interface for Reliable Static Routing Backup Using Object Tracking
Configuring the Primary Interface for PPPoE
Configuring the Primary Interface for DHCP
Configuring the Primary Interface for Static Routing
Configuring the Backup Interface for Reliable Static Routing Backup Using Object Tracking
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.3(8)T, 12.3(11)T, and 12.2(33)SRA
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.3(14)T, 12.4, 12.4(2)T, and 12.2(33)SXH
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.4(4)T and Later Releases
Configuring the Routing Policy for Reliable Static Routing Backup Using Object Tracking
Configuring a Routing Policy for PPPoE
Configuring a Routing Policy for DHCP
Configuring a Routing Policy for Static Routing
Configuring the Default Route for the Primary Interface Using Static Routing
Configuring a Floating Static Default Route on the Secondary Interface
Verifying the State of the Tracked Object for Reliable Static Routing Backup Using Object Tracking
Configuration Examples for Reliable Static Routing Backup Using Object Tracking
Configuring Reliable Static Routing Backup Using Object Tracking: PPPoE Example
Configuring Reliable Static Routing Backup Using Object Tracking: DHCP Example
Configuring Reliable Static Routing Backup Using Object Tracking: Static Routing Examples
Verifying the State of the Tracked Object: Example
Reliable Static Routing Backup Using Object Tracking
The Reliable Static Routing Backup Using Object Tracking feature introduces the ability for the Cisco IOS software to use Internet Control Message Protocol (ICMP) pings to identify when a Point-to-Point over Ethernet (PPPoE) or IP Security Protocol (IPSec) Virtual Private Network (VPN) tunnel goes down, allowing the initiation of a backup connection from any alternative port. The Reliable Static Routing Backup Using Object Tracking feature is compatible with both preconfigured static routes and Dynamic Host Configuration Protocol (DHCP) configurations.
Feature History for Reliable Static Routing Backup Using Object Tracking
Finding Support Information for Platforms and Cisco IOS Software Images
Use Cisco Feature Navigator to find information about platform support and Cisco IOS software image support. Access Cisco Feature Navigator at http://www.cisco.com/go/fn. You must have an account on Cisco.com. If you do not have an account or have forgotten your username or password, click Cancel at the login dialog box and follow the instructions that appear.
Contents
•
Prerequisites for Reliable Static Routing Backup Using Object Tracking
•
Restrictions for Reliable Static Routing Backup Using Object Tracking
•
Information About Reliable Static Routing Backup Using Object Tracking
•
How to Configure Reliable Static Routing Backup Using Object Tracking
•
Configuration Examples for Reliable Static Routing Backup Using Object Tracking
Prerequisites for Reliable Static Routing Backup Using Object Tracking
Dial-on-demand routing (DDR) must be configured if the backup connection is configured on a dialer interface. For more information on configuring DDR, refer to the "Dial-on-Demand Routing Configuration" part of the Cisco IOS Dial Technologies Configuration Guide.
Restrictions for Reliable Static Routing Backup Using Object Tracking
This feature is supported in all Cisco IOS software images for the Cisco 1700 series modular access routers except the Cisco IOS IP Base image.
Information About Reliable Static Routing Backup Using Object Tracking
To configure the Reliable Static Routing Backup Using Object Tracking feature, you should understand the following concepts:
•
Reliable Static Routing Backup Using Object Tracking
•
Benefits of Reliable Static Routing Backup Using Object Tracking
Reliable Static Routing Backup Using Object Tracking
The Reliable Static Routing Backup Using Object Tracking feature introduces the ability to reliably back up PPPoE or IPSec VPN deployments by initiating a DDR connection from an alternative port if the circuit to the primary gateway is interrupted. The Reliable Static Routing Backup Using Object Tracking feature can ensure reliable backup in the case of several catastrophic events, such as Internet circuit failure or peer device failure. A typical scenario is shown in Figure 1.
Figure 1
Reliable Static Routing Backup Using Object Tracking Network Diagram
Traffic from the remote LAN is forwarded to the main office from the primary interface of the remote router. If the connection to the main office is lost, the status of the tracked object changes from up to down. When the state of the tracked object changes to down, the routing table entry for the primary interface is removed and the preconfigured floating static route is installed on the secondary interface. Traffic is then forwarded to the preconfigured destination from the secondary interface. If DDR is configured on the secondary interface, interesting traffic will trigger DDR. The backup circuit can be configured to use the public switched telephone network (PSTN) or the Internet. When the state of the tracked object changes from down to up, the routing table entry for the primary interface is reinstalled and the floating static route for the secondary interface is removed.
Cisco IOS IP SLAs
The Reliable Static Routing Backup Using Object Tracking feature uses Cisco IOS IP SLAs, a network monitoring feature set, to generate ICMP pings to monitor the state of the connection to the primary gateway. Cisco IOS IP SLAs is configured to ping a target, such as a publicly routable IP address or a target inside the corporate network. The pings are routed from the primary interface only. A track object is created to monitor the status of the Cisco IOS IP SLAs configuration. The track object informs the client, the static route, if a state change occurs. The preconfigured floating static route on the secondary interface will be installed when the state changes from up to down.
HTTP GET, User Datagram Protocol (UDP) echo, or any other protocol supported by Cisco IOS IP SLAs can be used instead of ICMP pings.
Benefits of Reliable Static Routing Backup Using Object Tracking
PPPoE and IPSec VPN deployments provide cost-effective and secure Internet-based solutions that can replace traditional dialup and Frame Relay circuits.
The Reliable Static Routing Backup Using Object Tracking feature can determine the state of the primary connection without enabling a dynamic routing protocol.
The Reliable Static Routing Backup Using Object Tracking feature introduces a reliable backup solution for PPPoE and IPSec VPN deployments, allowing these solutions to be used for critical circuits that must not go down without a backup circuit automatically engaging.
How to Configure Reliable Static Routing Backup Using Object Tracking
This section contains the following tasks:
•
Configuring the Primary Interface for Reliable Static Routing Backup Using Object Tracking (required)
•
Configuring the Backup Interface for Reliable Static Routing Backup Using Object Tracking (required)
•
Configuring the Routing Policy for Reliable Static Routing Backup Using Object Tracking (required)
•
Configuring the Default Route for the Primary Interface Using Static Routing (required)
•
Configuring a Floating Static Default Route on the Secondary Interface (required)
•
Verifying the State of the Tracked Object for Reliable Static Routing Backup Using Object Tracking (optional)
Configuring the Primary Interface for Reliable Static Routing Backup Using Object Tracking
You must configure the connection between the primary interface and the remote gateway. The status of this connection will be monitored by the Reliable Static Routing Backup Using Object Tracking feature.
The primary interface can be configured in one of three ways: for PPPoE, DHCP, or static routing. You must choose one of these configuration types. If you are unsure of which method to use with your network configuration, consult your Internet service provider (ISP) or network administrator.
Perform one of the following tasks to configure the primary interface:
•
Configuring the Primary Interface for PPPoE
•
Configuring the Primary Interface for DHCP
•
Configuring the Primary Interface for Static Routing
Configuring the Primary Interface for PPPoE
Perform this task to configure the primary interface if you are using PPPoE.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
interface type number [name-tag]
4.
description string
5.
no ip address
6.
pvc [name] vpi/vci [ces | ilmi | qsaal | smds | l2transport]
7.
pppoe-client dial-pool-number number [dial-on-demand]
DETAILED STEPS
Configuring the Primary Interface for DHCP
Perform this task to configure the primary interface if you are using DHCP.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
interface type number [name-tag]
4.
description string
5.
ip dhcp client route track number
6.
ip address dhcp
DETAILED STEPS
Configuring the Primary Interface for Static Routing
Perform this task to configure the primary interface if you are using static routing.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
interface type number [name-tag]
4.
description string
5.
ip address ip-address mask [secondary]
DETAILED STEPS
Configuring the Backup Interface for Reliable Static Routing Backup Using Object Tracking
You must configure a backup interface to contact the remote gateway. If the connection between the primary interface and the remote gateway goes down, the backup interface will be used.
Perform the following task to configure the backup interface. This task applies to PPPoE, DHCP, and static routing configurations.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
interface type number [name-tag]
4.
description string
5.
ip address ip-address mask [secondary]
DETAILED STEPS
Configuring Network Monitoring with Cisco IOS IP SLAs for Reliable Static Routing Backup Using Object Tracking
The Reliable Static Routing Backup Using Object Tracking feature uses a Cisco IOS IP SLAs configuration to generate ICMP pings to monitor the state of the connection to the primary gateway.
Beginning in Cisco IOS Release 12.3(14)T, the CLI used to configure Cisco IOS IP SLAs was modified.
Perform one of the following tasks to configure Cisco IOS IP SLAs depending on which Cisco IOS software release you are running:
•
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.3(8)T, 12.3(11)T, and 12.2(33)SRA
•
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.3(14)T, 12.4, 12.4(2)T, and 12.2(33)SXH
•
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.4(4)T and Later Releases
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.3(8)T, 12.3(11)T, and 12.2(33)SRA
Perform this task to create an IP SLAs configuration to ping the target address. This task applies to PPPoE, DHCP, and static routing configurations.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
rtr [operation-number]
4.
type echo protocol ipIcmpEcho {destination-ip-address | destination-hostname} [source-ipaddr {ip-address | hostname}
5.
timeout milliseconds
6.
frequency seconds
7.
threshold milliseconds
8.
exit
9.
rtr schedule operation-number [life {forever | seconds}] [start-time {hh:mm[:ss] [month day | day month] | pending | now | after hh:mm:ss}] [ageout seconds]
10.
track object-number rtr rtr-operation {state | reachability}
DETAILED STEPS
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.3(14)T, 12.4, 12.4(2)T, and 12.2(33)SXH
Perform this task to create an IP SLAs configuration to ping the target address. This task applies to PPPoE, DHCP, and static routing configurations.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
ip sla monitor [operation-number]
4.
type echo protocol ipIcmpEcho {destination-ip-address | destination-hostname} [source-ipaddr {ip-address | hostname} | source-interface interface-name]
5.
timeout milliseconds
6.
frequency seconds
7.
threshold milliseconds
8.
exit
9.
ip sla monitor schedule operation-number [life {forever | seconds}] [start-time {hh:mm[:ss] [month day | day month] | pending | now | after hh:mm:ss}] [ageout seconds] [recurring]
10.
track object-number rtr rtr-operation {state | reachability}
DETAILED STEPS
Configuring Cisco IOS IP SLAs for Cisco IOS Release 12.4(4)T and Later Releases
Perform this task to create an IP SLAs configuration to ping the target address. This task applies to PPPoE, DHCP, and static routing configurations.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
ip sla [operation-number]
4.
icmp-echo {destination-ip-address | destination-hostname} [source-ip {ip-address | hostname} | source-interface interface-name]
5.
timeout milliseconds
6.
frequency seconds
7.
threshold milliseconds
8.
exit
9.
ip sla schedule operation-number [life {forever | seconds}] [start-time {hh:mm[:ss] [month day | day month] | pending | now | after hh:mm:ss}] [ageout seconds] [recurring]
10.
track object-number rtr rtr-operation {state | reachability}
DETAILED STEPS
Configuring the Routing Policy for Reliable Static Routing Backup Using Object Tracking
In order to track the status of the primary connection to the remote gateway, the Cisco IOS IP SLAs ICMP pings must be routed only from the primary interface.
Perform one of the following tasks to configure a routing policy that will ensure that the Cisco IOS IP SLAs pings are always routed out of the primary interface:
•
Configuring a Routing Policy for PPPoE
•
Configuring a Routing Policy for DHCP
•
Configuring a Routing Policy for Static Routing
Configuring a Routing Policy for PPPoE
Perform this task to configure a routing policy if the primary interface is configured for PPPoE.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
access-list access-list-number [dynamic dynamic-name [timeout minutes]] {deny | permit} icmp source source-wildcard destination destination-wildcard [icmp-type [icmp-code] | icmp-message] [precedence precedence] [tos tos] [log | log-input] [time-range time-range-name] [fragments]
4.
route-map map-tag [permit | deny] [sequence-number]
5.
match ip address {access-list-number | access-list-name} [... access-list-number | ... access-list-name]
6.
set interface type number [... type number]
7.
exit
8.
ip local policy route-map map-tag
DETAILED STEPS
Configuring a Routing Policy for DHCP
Perform this task to configure a routing policy if the primary interface is configured for DHCP.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
access-list access-list-number [dynamic dynamic-name [timeout minutes]] {deny | permit} icmp source source-wildcard destination destination-wildcard [icmp-type [icmp-code] | icmp-message] [precedence precedence] [tos tos] [log | log-input] [time-range time-range-name] [fragments]
4.
route-map map-tag [permit | deny] [sequence-number]
5.
match ip address {access-list-number | access-list-name} [... access-list-number | ... access-list-name]
6.
set ip next-hop dynamic dhcp
7.
exit
8.
ip local policy route-map map-tag
DETAILED STEPS
Configuring a Routing Policy for Static Routing
Perform one of the following tasks if the primary interface is configured for static routing:
•
Configuring a Routing Policy for Static Routing with a Point-to-Point Primary Gateway
•
Configuring a Routing Policy for Static Routing with a Multipoint Primary Gateway
Configuring a Routing Policy for Static Routing with a Point-to-Point Primary Gateway
Perform this task to configure a routing policy if the primary interface is configured for static routing and the primary gateway is a point-to-point gateway.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
access-list access-list-number [dynamic dynamic-name [timeout minutes]] {deny | permit} icmp source source-wildcard destination destination-wildcard [icmp-type [icmp-code] | icmp-message] [precedence precedence] [tos tos] [log | log-input] [time-range time-range-name] [fragments]
4.
route-map map-tag [permit | deny] [sequence-number]
5.
match ip address {access-list-number | access-list-name} [... access-list-number | ... access-list-name]
6.
set interface type number [... type number]
7.
exit
8.
ip local policy route-map map-tag
DETAILED STEPS
Configuring a Routing Policy for Static Routing with a Multipoint Primary Gateway
Perform this task to configure a routing policy if the primary interface is configured for static routing and the primary gateway is a multipoint gateway.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
access-list access-list-number [dynamic dynamic-name [timeout minutes]] {deny | permit} icmp source source-wildcard destination destination-wildcard [icmp-type [icmp-code] | icmp-message] [precedence precedence] [tos tos] [log | log-input] [time-range time-range-name] [fragments]
4.
route-map map-tag [permit | deny] [sequence-number]
5.
match ip address {access-list-number | access-list-name} [... access-list-number | ... access-list-name]
6.
set ip next-hop ip-address [... ip-address]
7.
set interface type number [... type number]
8.
exit
9.
ip local policy route-map map-tag
DETAILED STEPS
Configuring the Default Route for the Primary Interface Using Static Routing
Perform this task to configure the static default route only if you are using static routing.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
ip route prefix mask {ip-address | interface-type interface-number [ip-address]} [distance] [name] [permanent | track number] [tag tag]
DETAILED STEPS
Configuring a Floating Static Default Route on the Secondary Interface
Perform this task to configure a floating static default route on the secondary interface. This task applies to PPPoE, DHCP, and static routing configurations.
SUMMARY STEPS
1.
enable
2.
configure terminal
3.
ip route network-number network-mask {ip-address | interface} [distance] [name name]
DETAILED STEPS
Verifying the State of the Tracked Object for Reliable Static Routing Backup Using Object Tracking
Perform the following task to determine if the state of the tracked object is up or down.
SUMMARY STEPS
1.
enable
2.
show ip route track-table
DETAILED STEPS
Configuration Examples for Reliable Static Routing Backup Using Object Tracking
This section provides the following configuration examples:
•
Configuring Reliable Static Routing Backup Using Object Tracking: PPPoE Example
•
Configuring Reliable Static Routing Backup Using Object Tracking: DHCP Example
•
Configuring Reliable Static Routing Backup Using Object Tracking: Static Routing Examples
•
Verifying the State of the Tracked Object: Example
Configuring Reliable Static Routing Backup Using Object Tracking: PPPoE Example
The following example configures the Reliable Static Routing Backup Using Object Tracking feature using PPPoE. The primary interface is an ATM interface, and the backup interface is a BRI interface. This example applies to Cisco IOS Release 12.3(8)T, 12.3(11)T, 12.2(33)SRA, and 12.2(33)SXH.
interface ATM 0description primary-linkno ip addresspvc 0/33pppoe-client dial-pool-number 1!interface BRI 0description backup-linkip address 10.2.2.2 255.0.0.0!rtr 1type echo protocol ipIcmpEcho 172.16.23.7timeout 1000frequency 3threshold 2rtr schedule 1 life forever start-time nowtrack 123 rtr 1 reachabilityaccess list 101 permit icmp any host 172.16.23.7 echoroute map MY-LOCAL-POLICY permit 10match ip address 101set interface null 0!ip local policy route-map MY-LOCAL-POLICYip route 0.0.0.0 0.0.0.0 10.2.2.125 254Configuring Reliable Static Routing Backup Using Object Tracking: DHCP Example
The following example configures the Reliable Static Routing Backup Using Object Tracking feature using DHCP. The primary interface is an Ethernet interface, and the backup interface is a serial interface. This example applies to Cisco IOS Release 12.3(14)T and later releases.
!ip dhcp-client default-router distance 25ip sla monitor 1type echo protocol ipIcmpEcho 172.16.23.7timeout 1000threshold 2frequency 3ip sla monitor schedule 1 life forever start-time nowtrack 123 rtr 1 reachability!interface Ethernet0/0description primary-linkip dhcp client route track 123ip address dhcp!interface Serial2/0description backup-linkip address 10.2.2.2 255.0.0.0!ip local policy route-map MY-LOCAL-POLICYip route 0.0.0.0 0.0.0.0 10.2.2.125 254!access-list 101 permit icmp any host 172.16.23.7 echoroute-map MY-LOCAL-POLICY permit 10match ip address 101set ip next-hop dynamic dhcpConfiguring Reliable Static Routing Backup Using Object Tracking: Static Routing Examples
The following example configures the Reliable Static Routing Backup Using Object Tracking feature using static routing for a point-to-point primary gateway. The primary interface is a PPPoE Fast Ethernet interface, and the backup interface is a dialer interface. This example applies to Cisco IOS Release 12.3(14)T and later releases.
interface FastEthernet 0/0description primary-linkip address 10.1.1.1 255.0.0.0interface Dialer 0description backup-linkip address 10.2.2.2 255.0.0.0ip sla monitor 1type echo protocol ipIcmpEcho 172.16.23.7timeout 1000frequency 3threshold 2ip sla monitor schedule 1 life forever start-time nowtrack 123 rtr 1 reachabilityaccess list 101 permit icmp any host 172.16.23.7 echoroute map MY-LOCAL-POLICY permit 10match ip address 101set interface dialer 0 null 0!ip local policy route-map MY-LOCAL-POLICYip route 0.0.0.0 0.0.0.0 10.1.1.242 track 123ip route 0.0.0.0 0.0.0.0 10.2.2.125 254The following example configures the Reliable Static Routing Backup Using Object Tracking feature using static routing for a multipoint primary gateway. Both the primary interface and the backup interface are Ethernet interfaces. This example applies to Cisco IOS Release 12.3(14)T and later releases.
interface ethernet 0description primary-linkip address 10.1.1.1 255.0.0.0interface ethernet 1description backup-linkip address 10.2.2.2 255.0.0.0ip sla monitor 1type echo protocol ipIcmpEcho 172.16.23.7timeout 1000frequency 3threshold 2ip sla monitor schedule 1 life forever start-time nowtrack 123 rtr 1 reachabilityaccess list 101 permit icmp any host 172.16.23.7 echoroute map MY-LOCAL-POLICY permit 10match ip address 101set ip next-hop 10.1.1.242set interface null 0!ip local policy route-map MY-LOCAL-POLICYip route 0.0.0.0 0.0.0.0 10.1.1.242 track 123ip route 0.0.0.0 0.0.0.0 10.2.2.125 254Verifying the State of the Tracked Object: Example
The following example displays information about track objects in the IP route track table:
Router# show ip route track-tableip route 0.0.0.0 0.0.0.0 10.1.1.242 track-object 123 state is [up]Additional References
The following sections provide references related to the Reliable Static Routing Backup Using Object Tracking feature.
Related Documents
Standards
MIBs
MIBs MIBs LinkNone
To locate and download MIBs for selected platforms, Cisco IOS releases, and feature sets, use Cisco MIB Locator found at the following URL:
RFCs
Technical Assistance
Command Reference
This section documents onlycommands that are new or modified .
ip dhcp client
To configure the Dynamic Host Configuration Protocol (DHCP) client to associate any added routes with a specified tracked object number, use the ip dhcp client command in interface configuration mode. To restore the default setting, use the no form of this command.
ip dhcp client route track number
no ip dhcp client route track
Syntax Description
route track number
Associates a tracked object number with the DHCP-installed static route. Valid values for the number argument range from 1 to 500.
Defaults
No routes are associated with a track number.
Command Modes
Interface configuration
Command History
Usage Guidelines
The ip dhcp client command must be configured before the ip address dhcp command is configured on an interface. The ip dhcp client command is checked only when an IP address is acquired from DHCP. If the ip dhcp client command is specified after an IP address has been acquired from DHCP, the ip dhcp client command will not take effect until the next time the router acquires an IP address from DHCP.
Examples
The following example configures DHCP on an Ethernet interface and associates tracked object 123 with routes generated from this interface:
interface ethernet 0/0ip dhcp client route track 123ip address dhcpRelated Commands
ip route
To establish static routes, use the ip route command in global configuration mode. To remove static routes, use the no form of this command.
ip route prefix mask {ip-address | interface-type interface-number [ip-address]} [dhcp] [distance] [name] [permanent | track number] [tag tag]
no ip route prefix mask
Syntax Description
Defaults
No static routes are established.
Command Modes
Global configuration
Command History
Usage Guidelines
The establishment of a static route is appropriate when the Cisco IOS software cannot dynamically build a route to the destination.
When you specify a DHCP server to assign a static route, the interface type and number and administrative distance may be configured also.
If you specify an administrative distance, you are flagging a static route that can be overridden by dynamic information. For example, routes derived with Enhanced Interior Gateway Routing Protocol (EIGRP) have a default administrative distance of 100. To have a static route that would be overridden by an EIGRP dynamic route, specify an administrative distance greater than 100. Static routes have a default administrative distance of 1.
Static routes that point to an interface on a connected router will be advertised by way of Routing Information Protocol (RIP) and EIGRP regardless of whether redistribute static commands are specified for those routing protocols. This situation occurs because static routes that point to an interface are considered in the routing table to be connected and hence lose their static nature. Also, the target of the static route should be included in the network (DHCP) command. If this condition is not met, no dynamic routing protocol will advertise the route unless a redistribute static command is specified for these protocols. With the following configuration:
rtr1 (serial 172.16.188.1/30)--------------> rtr2(Fast Ethernet 172.31.1.1/30) ------>router [rip | eigrp]network 172.16.188.0network 172.31.0.0•
RIP and EIGRP redistribute the route if the route is pointing to the Fast Ethernet interface:
ip route 172.16.188.252 255.255.255.252 FastEthernet 0/0RIP and EIGRP do not redistribute the route with the following ip route command because of the split horizon algorithm:
ip route 172.16.188.252 255.255.255.252 serial 2/1•
EIGRP redistributes the route with both of the following commands:
ip route 172.16.188.252 255.255.255.252 FastEthernet 0/0ip route 172.16.188.252 255.255.255.252 serial 2/1With the Open Shortest Path First (OSPF) protocol, static routes that point to an interface are not advertised unless a redistribute static command is specified.
Adding a static route to an Ethernet or other broadcast interface (for example, ip route 0.0.0.0 0.0.0.0 Ethernet 1/2) will cause the route to be inserted into the routing table only when the interface is up. This configuration is not generally recommended. When the next hop of a static route points to an interface, the router considers each of the hosts within the range of the route to be directly connected through that interface, and therefore it will send Address Resolution Protocol (ARP) requests to any destination addresses that route through the static route.
The practical implication of configuring the ip route 0.0.0.0 0.0.0.0 ethernet 1/2 command is that the router will consider all of the destinations that the router does not know how to reach through some other route as directly connected to Ethernet interface 1/2. So the router will send an ARP request for each host for which it receives packets on this network segment. This configuration can cause high processor utilization and a large ARP cache (along with memory allocation failures). Configuring a default route or other static route that directs the router to forward packets for a large range of destinations to a connected broadcast network segment can cause your router to reload.
Specifying a numerical next hop that is on a directly connected interface will prevent the router from using proxy ARP. However, if the interface with the next hop goes down and the numerical next hop can be reached through a recursive route, you may specify both the next hop and interface (for example, ip route 0.0.0.0 0.0.0.0 ethernet 1/2 10.1.2.3) with a static route to prevent routes from passing through an unintended interface.
The track number keyword and argument combination specifies that the static route will be installed only if the state of the configured track object is up.
Examples
The following example chooses an administrative distance of 110. In this case, packets for network 10.0.0.0 will be routed to a router at 172.31.3.4 if dynamic information with an administrative distance less than 110 is not available.
ip route 10.0.0.0 255.0.0.0 172.31.3.4 110
Note
Specifying the next hop without specifying an interface when configuring a static route can cause traffic to pass through an unintended interface if the default interface goes down.
The following example routes packets for network 172.31.0.0 to a router at 172.31.6.6:
ip route 172.31.0.0 255.255.0.0 172.31.6.6The following example routes packets for network 192.168.1.0 directly to the next hop at 10.1.2.3. If the interface goes down, this route is removed from the routing table and will not be restored unless the interface comes back up.
ip route 192.168.1.0 255.255.0.0 Ethernet 0 10.1.2.3The following example installs the static route only if the state of track object 123 is up:
ip route 0.0.0.0 0.0.0.0 Ethernet 0/1 10.1.1.242 track 123The following example shows that using the dhcp keyword in a configuration of Ethernet interfaces 1 and 2 enables the interfaces to obtain the next-hop router IP addresses dynamically from a DHCP server:
ip route 10.165.200.225 255.255.255.255 ether1 dhcpip route 10.165.200.226 255.255.255.255 ether2 dhcp 20Related Commands
set ip next-hop dynamic dhcp
To set the next hop to the gateway that was most recently learned by the Dynamic Host Configuration Protocol (DHCP) client, use the set ip next-hop dynamic dhcp command in route-map configuration mode. To restore the default setting, use the no form of this command.
set ip next-hop dynamic dhcp
no set ip next-hop dynamic dhcp
Syntax Description
This command has no arguments or keywords.
Defaults
This command is disabled by default.
Command Modes
Route-map configuration
Command History
Usage Guidelines
The set ip next-hop dynamic dhcp command supports only a single DHCP interface. If multiple interfaces have DHCP configured, the gateway that was most recently learned among all interfaces running DHCP will be used by the route map.
Examples
The following example configures a local routing policy that sets the next hop to the gateway that was most recently learned by the DHCP client:
access list 101 permit icmp any host 172.16.23.7 echoroute map MY-LOCAL-POLICY permit 10match ip address 101set ip next-hop dynamic dhcp!ip local policy route-map MY-LOCAL-POLICYRelated Commands
show ip route track-table
To display information about the IP route track table, use the show ip route track-table command in privileged EXEC mode.
show ip route track-table
Syntax Description
This command has no arguments or keywords.
Command Modes
Privileged EXEC
Command History
Examples
The following example displays information about the IP route track table:
Router# show ip route track-tableip route 0.0.0.0 0.0.0.0 10.1.1.242 track-object 123 state is [up]Table 1 describes the significant fields shown in the display.
© 2003—2007 Cisco Systems, Inc. All rights reserved.



