![]() |
Table Of Contents
OSPF Stub Router Advertisement
Allowing Routing Tables to Converge
Configuring a Graceful Shutdown
Related Features and Technologies
Supported Standards, MIBs, and RFCs
Configuring Advertisement on Startup
Configuring Advertisement Until Routing Tables Converge
Configuring Advertisement for a Graceful Shutdown
Verifying the Advertisement of a Maximum Metric
Monitoring and Maintaining OSPF Stub Router Advertisement
Advertisement on Startup Example
Advertisement Until Routing Tables Converge Example
OSPF Stub Router Advertisement
Feature History
This document describes the OSPF Stub Router Advertisement feature. It includes the following sections:
•
Related Features and Technologies
•
Supported Standards, MIBs, and RFCs
•
Monitoring and Maintaining OSPF Stub Router Advertisement
Feature Overview
The OSPF Stub Router Advertisement feature allows you to bring a new router into a network without immediately routing traffic through the new router and allows you to gracefully shut down or reload a router without dropping packets that are destined for other networks. This feature introduces three configuration options that allow you to configure a router that is running the Open Shortest Path First (OSPF) protocol to advertise a maximum or infinite metric to all neighbors.
When any of these three configuration options are enabled on a router, the router will originate link-state advertisements (LSAs) with a maximum metric (LSInfinity: 0xFFFF) through all nonstub links. The advertisement of a maximum metric causes other routers to assign a cost to the new router that is higher than the cost of using an alternate path. Because of the high cost assigned to paths that pass through the new router, other routers will not use a path through the new router as a transit path to forward traffic that is destined for other networks, which allows switching and routing functions to be up and running and routing tables to converge before transit traffic is routed through this router.
Note
Directly connected links in a stub network are not affected by the configuration of a maximum or infinite metric because the cost of a stub link is always set to the output interface cost.
Allowing Routing Tables to Converge
Two configuration options introduced by the OSPF Stub Router Advertisement feature allow you to bring a new router into a network without immediately routing traffic through the new router. These configuration options are useful because Interior Gateway Protocols (IGPs) converge very quickly upon a router during startup or after a reload, often before Border Gateway Protocol (BGP) routing tables have completely converged. If neighbor routers forward traffic through a router while that router is building BGP routing tables, packets that have been received for other destinations may be dropped. Advertising a maximum metric during startup will allow routing tables to converge before traffic that is destined for other networks is sent through the router. The following two configuration options enable a router to advertise a maximum metric at startup:
•
You can configure a timer to advertise a maximum metric when the router is started or reloaded. When this option is configured, the router will advertise a maximum metric, which forces neighbor routers to select alternate paths until the timer expires. When the timer expires, the router will advertise accurate (normal) metrics, and other routers will send traffic to this router depending on the cost. The configurable range of the timer is from 5 to 86,400 seconds.
•
You can configure a router to advertise a maximum metric at startup until BGP routing tables converge or until the default timer expires (600 seconds). Once BGP routing tables converge or the default timer expires, the router will advertise accurate (normal) metrics and other routers will send traffic to this router, depending on the cost.
Configuring a Graceful Shutdown
The third configuration option introduced by the OSPF Stub Router Advertisement feature allows you to gracefully remove a router from the network by advertising a maximum metric through all links, which allows other routers to select alternate paths for transit traffic to follow before the router is shut down. There are many situations where you may need to remove a router from the network. If a router is removed from a network and neighbor routers cannot detect that the physical interface is down, neighbors will need to wait for dead timers to expire before the neighbors will remove the adjacency and routing tables will reconverge. This situation may occur when there is a switch between other routers and the router that is shut down. Packets may be dropped while the neighbor routing tables reconverge.
When this third option is configured, the router advertises a maximum metric, which allows neighbor routers to select alternate paths before the router is shut down. This configuration option could also be used to remove a router that is in a critical condition from the network without affecting traffic that is destined for other networks.
Note
You should not save the running configuration of a router when it is configured for a graceful shutdown because the router will continue to advertise a maximum metric after it is reloaded.
Benefits
Improved Stability and Availability
Advertising a maximum metric through all links at startup or during a reload will prevent neighbor routers from using a path through the router as a transit path, thereby reducing the number of packets that are dropped and improving the stability and availability of the network.
Graceful Removal from the Network
Advertising a maximum metric before shutdown allows other routers to select alternate paths before the transit path through a router becomes inaccessible.
Related Features and Technologies
The OSPF Stub Router Advertisement feature is an extension of the OSPF routing protocol. For more information about configuring OSPF and BGP, refer to the Release 12.2 Cisco IOS IP Routing Configuration Guide and the Cisco IOS IP Command Reference, Volume 2 of 3: Routing Protocols.
Supported Platforms
The OSPF Stub Router Advertisement feature is supported by the following platforms in Cisco IOS Release 12.2(14)S that support OSPF:
•
Cisco 7200 series
•
Cisco 7400 series
•
Cisco 7500 series
Determining Platform Support Through Cisco Feature Navigator
Cisco IOS software is packaged in feature sets that support specific platforms. To get updated information regarding platform support for this feature, access Cisco Feature Navigator. Cisco Feature Navigator dynamically updates the list of supported platforms as new platform support is added for the feature.
Cisco Feature Navigator is a web-based tool that enables you to determine which Cisco IOS software images support a specific set of features and which features are supported in a specific Cisco IOS image. You can search by feature or release. Under the release section, you can compare releases side by side to display both the features unique to each software release and the features in common.
To access Cisco Feature Navigator, you must have an account on Cisco.com. If you have forgotten or lost your account information, send a blank e-mail to cco-locksmith@cisco.com. An automatic check will verify that your e-mail address is registered with Cisco.com. If the check is successful, account details with a new random password will be e-mailed to you. Qualified users can establish an account on Cisco.com by following the directions at http://www.cisco.com/register.
Cisco Feature Navigator is updated regularly when major Cisco IOS software releases and technology releases occur. For the most current information, go to the Cisco Feature Navigator home page at the following URL:
Availability of Cisco IOS Software Images
Platform support for particular Cisco IOS software releases is dependent on the availability of the software images for those platforms. Software images for some platforms may be deferred, delayed, or changed without prior notice. For updated information about platform support and availability of software images for each Cisco IOS software release, refer to the online release notes or, if supported, Cisco Feature Navigator.
Supported Standards, MIBs, and RFCs
Standards
No new or modified standards are supported by this feature.
MIBs
No new or modified MIBs are supported by this feature.
To obtain lists of supported MIBs by platform and Cisco IOS release, and to download MIB modules, go to the Cisco MIB website on Cisco.com at the following URL:
http://www.cisco.com/public/sw-center/netmgmt/cmtk/mibs.shtml
RFCs
•
RFC 3137 OSPF Stub Router Advertisement
Configuration Tasks
See the following sections for configuration tasks to configure OSPF to advertise a maximum metric. This feature has three different configuration options. All tasks are optional and should be individually configured.
•
Configuring Advertisement on Startup (optional)
•
Configuring Advertisement Until Routing Tables Converge (optional)
•
Configuring Advertisement for a Graceful Shutdown (optional)
•
Verifying the Advertisement of a Maximum Metric (optional)
Configuring Advertisement on Startup
To configure a router that is running OSPF to advertise a maximum metric during startup, use the following commands beginning in global configuration mode:
Configuring Advertisement Until Routing Tables Converge
To configure a router that is running OSPF to advertise a maximum metric until BGP routing tables converge, use the following commands beginning in global configuration mode:
Configuring Advertisement for a Graceful Shutdown
To configure a router that is running OSPF to advertise a maximum metric for a graceful shutdown or removal from the network, use the following commands beginning in global configuration mode:
Note
You should not save the running configuration of a router when it is configured for a graceful shutdown because the router will continue to advertise a maximum metric after it is reloaded.
Verifying the Advertisement of a Maximum Metric
To verify that the advertisement of a maximum metric has been configured correctly, use the show ip ospf or show ip ospf database command.
The output of the show ip ospf command will display the condition, state, and remaining time delay of the advertisement of a maximum metric, depending on which options were configured with the max-metric router-lsa command.
The following sample output is similar to the output that will be displayed when the on-startup keyword and announce-time argument are configured with the max-metric router-lsa command:
Router# show ip ospf
Routing Process "ospf 1998" with ID 10.18.134.155Supports only single TOS(TOS0) routesSupports opaque LSAIt is an area border and autonomous system boundary routerRedistributing External Routes from,static, includes subnets in redistributionOriginating router-LSAs with maximum metric, Time remaining: 00:01:18Condition: on startup for 300 seconds, State: activeSPF schedule delay 5 secs, Hold time between two SPFs 10 secsMinimum LSA interval 5 secs. Minimum LSA arrival 1 secsNumber of external LSA 7. Checksum Sum 0x47261Number of opaque AS LSA 0. Checksum Sum 0x0Number of DCbitless external and opaque AS LSA 0Number of DoNotAge external and opaque AS LSA 0Number of areas in this router is 2. 1 normal 0 stub 1 nssaExternal flood list length 0Area BACKBONE(0)Number of interfaces in this area is 1Area has no authenticationSPF algorithm executed 3 timesArea ranges areNumber of LSA 8. Checksum Sum 0x474AENumber of opaque link LSA 0. Checksum Sum 0x0The following sample output is similar to the output that will be displayed when the on-startup and wait-for-bgp keywords are configured with the max-metric router-lsa command:
Router# show ip ospf
Routing Process "ospf 1998" with ID 10.18.134.155Supports only single TOS(TOS0) routesSupports opaque LSAIt is an area border and autonomous system boundary routerRedistributing External Routes from,static, includes subnets in redistributionOriginating router-LSAs with maximum metric, Time remaining: 00:01:18Condition: on startup while BGP is converging, State: activeSPF schedule delay 5 secs, Hold time between two SPFs 10 secsMinimum LSA interval 5 secs. Minimum LSA arrival 1 secsNumber of external LSA 7. Checksum Sum 0x47261Number of opaque AS LSA 0. Checksum Sum 0x0Number of DCbitless external and opaque AS LSA 0Number of DoNotAge external and opaque AS LSA 0Number of areas in this router is 2. 1 normal 0 stub 1 nssaExternal flood list length 0Area BACKBONE(0)Number of interfaces in this area is 1Area has no authenticationSPF algorithm executed 3 timesArea ranges areNumber of LSA 8. Checksum Sum 0x474AENumber of opaque link LSA 0. Checksum Sum 0x0The following sample output is similar to the output that will be displayed when the max-metric router-lsa command is configured without any keywords or arguments:
Router# show ip ospf
Routing Process "ospf 1998" with ID 10.18.134.155Supports only single TOS(TOS0) routesSupports opaque LSAIt is an area border and autonomous system boundary routerRedistributing External Routes from,static, includes subnets in redistributionOriginating router-LSAs with maximum metricCondition: always, State: activeSPF schedule delay 5 secs, Hold time between two SPFs 10 secsMinimum LSA interval 5 secs. Minimum LSA arrival 1 secsNumber of external LSA 7. Checksum Sum 0x47261Number of opaque AS LSA 0. Checksum Sum 0x0Number of DCbitless external and opaque AS LSA 0Number of DoNotAge external and opaque AS LSA 0Number of areas in this router is 2. 1 normal 0 stub 1 nssaExternal flood list length 0Area BACKBONE(0)Number of interfaces in this area is 1Area has no authenticationSPF algorithm executed 3 timesArea ranges areNumber of LSA 8. Checksum Sum 0x474AENumber of opaque link LSA 0. Checksum Sum 0x0The output of the show ip ospf database command will display information about OSPF LSAs and indicate if the router is announcing maximum cost links. The following sample output is similar to the output that will be displayed when any form of the max-metric router-lsa command is configured:
Router# show ip ospf database
Exception Flag: Announcing maximum link costsLS age: 68Options: (No TOS-capability, DC)LS Type: Router LinksLink State ID: 172.18.134.155Advertising Router: 172.18.134.155LS Seq Number: 80000002Checksum: 0x175DLength: 60Area Border RouterAS Boundary RouterNumber of Links: 3Link connected to: a Transit Network(Link ID) Designated Router address: 192.168.1.11(Link Data) Router Interface address: 192.168.1.14Number of TOS metrics: 0TOS 0 Metrics: 65535 (metric used for local calculation: 10)Link connected to: a Transit Network(Link ID) Designated Router address: 10.1.145.11(Link Data) Router Interface address: 10.1.145.14Number of TOS metrics: 0TOS 0 Metrics: 65535 (metric used for local calculation: 10)Link connected to: a Stub Network(Link ID) Network/subnet number: 10.11.12.0(Link Data) Network Mask: 255.255.255.0Number of TOS metrics: 0TOS 0 Metrics: 1Monitoring and Maintaining OSPF Stub Router Advertisement
To monitor and maintain the advertisement of a maximum metric, use the following EXEC commands:
Configuration Examples
This section provides the following configuration examples:
•
Advertisement on Startup Example
•
Advertisement Until Routing Tables Converge Example
Advertisement on Startup Example
In the following example, a router that is running OSPF is configured to advertise a maximum metric at startup for 300 seconds:
Router(config)# router ospf 100
Router(config-router)# max-metric router-lsa on-startup 300
Advertisement Until Routing Tables Converge Example
In the following example, a router that is running OSPF is configured to advertise a maximum metric until BGP routing tables converge or until the default timer expires (600 seconds):
Router(config)# router ospf 100
Router(config-router)# max-metric router-lsa on-startup wait-for-bgp
Graceful Shutdown Example
In the following example, a router that is running OSPF is configured to advertise a maximum metric until the router is shut down:
Router(config)# router ospf 100
Router(config-router)# max-metric router-lsa
Router(config-router)# exit
Router(config)# exit
Router# show ip ospf
Command Reference
This section documents new and modified commands. All other commands used with this feature are documented in the Cisco IOS Release 12.2 command reference publications.
New Command
Modified Command
max-metric router-lsa
To configure a router that is running the Open Shortest Path First (OSPF) protocol to advertise a maximum metric so that other routers do not prefer the router as an intermediate hop in their shortest path first (SPF) calculations, use the max-metric router-lsa command in router configuration mode. To disable the advertisement of a maximum metric, use the no form of this command.
max-metric router-lsa [on-startup {announce-time | wait-for-bgp}]
no max-metric router-lsa [on-startup {announce-time | wait-for-bgp}]
Syntax Description
Defaults
Router link-state advertisements (LSAs) are originated with normal link metrics.
Command Modes
Router configuration
Command History
Usage Guidelines
Enabling the max-metric router-lsa command will cause a router to originate LSAs with a maximum metric (LSInfinity: 0xFFFF) through all nonstub links, which allows BGP routing tables to converge without attracting transit traffic (if there are not alternate lower cost paths around the router). The router will advertise accurate (normal) metrics after the configured or default timers expire or after BGP sends a notification that routing tables have converged.
Note
Directly connected links in a stub network are not affected by the configuration of a maximum or infinite metric because the cost of a stub link is always set to the output interface cost.
The max-metric router-lsa command is useful in the following situations:
•
Reloading a router. After a router is reloaded, Interior Gateway Protocols (IGPs) converge very quickly, and other routers may try to forward traffic through the newly reloaded router. If the router is still building BGP routing tables, packets destined for other networks that the router has not learned through BGP may be dropped. In the case of an Internet backbone router, a large number of packets may be dropped.
•
Introducing a router into a network without routing traffic through it. You may want to connect a router to an OSPF network but not want real traffic flowing through the router if there are better alternate paths. If there are no alternate paths, then this router would still accept transit traffic as before.
•
Gracefully removing a router from a network. This feature allows you to gracefully remove a router from the network by advertising a maximum metric through all links, which allows other routers to select alternate paths for transit traffic to follow before the router is shut down.
Note
You should not save the running configuration of a router when it is configured for a graceful shutdown because the router will continue to advertise a maximum metric after it is reloaded.
Note
In older OSPF implementations (RFC 1247 and earlier implementations), the router link costs in received LSAs with a metric of LSInfinity are not used during SPF calculations, which means that no transit traffic will be sent to the routers originating these LSAs.
Examples
The following example configures a router that is running OSPF to advertise a maximum metric for 100 seconds:
Router(config)# router ospf 100
Router(config-router)# max-metric router-lsa on-startup 100
The following example configures a router to advertise a maximum metric until BGP routing tables converge or until the default timer expires (600 seconds):
Router(config)# router ospf 100
Router(config-router)# max-metric router-lsa on-startup wait-for-bgp
The following example configures a router that is running OSPF to advertise a maximum metric until the router shuts down:
Router(config)# router ospf 100
Router(config-router)# max-metric router-lsa
Router(config-router)# exit
Router(config)# exit
Router# show ip ospf
Related Commands
Command DescriptionDisplays general information about OSPF routing processes.
Displays lists of information related to the OSPF database for a specific router.
show ip ospf
To display general information about Open Shortest Path First (OSPF) routing processes, use the show ip ospf command in EXEC mode.
show ip ospf [process-id]
Syntax Description
process-id
(Optional) OSPF routing process ID. If this argument is included, only information for the specified routing process is included.
Command Modes
EXEC
Command History
Examples
The following is sample output from the show ip ospf command when entered without a specific OSPF process ID:
Router# show ip ospfRouting Process "ospf 200" with ID 10.18.134.155Supports only single TOS(TOS0) routesSupports opaque LSAIt is an area border and autonomous system boundary routerRedistributing External Routes from,static, includes subnets in redistributionOriginating router-LSAs with maximum metric, Time remaining: 00:01:18Condition: on startup for 300 seconds, State: activeSPF schedule delay 5 secs, Hold time between two SPFs 10 secsMinimum LSA interval 5 secs. Minimum LSA arrival 1 secsNumber of external LSA 7. Checksum Sum 0x47261Number of opaque AS LSA 0. Checksum Sum 0x0Number of DCbitless external and opaque AS LSA 0Number of DoNotAge external and opaque AS LSA 0Number of areas in this router is 2. 1 normal 0 stub 1 nssaExternal flood list length 0Area BACKBONE(0)Number of interfaces in this area is 1Area has no authenticationSPF algorithm executed 3 timesArea ranges areNumber of LSA 8. Checksum Sum 0x474AENumber of opaque link LSA 0. Checksum Sum 0x0Table 1 describes the significant fields shown in the display.