OSPF: Frequently Asked Questions

Q: What is OSPF?

A: OSPF is a link state routing protocol developed for IP networks. Each router maintains an identical database describing its area's topology. Then each router calculates its routing table by constructing a shortest path tree.

Q: What are the advantages of OSPF over other distance-vector routing protocols like IGRP and RIP?

A: OSPF, being a link state routing protocol, is designed to recalculate routes quickly in the face of topological changes. This is called Fast Network Convergence. It uses a minimum of routing protocol traffic, so it provides better convergence time. It also allows different subnets of the same IP network number to have different masks. This is called Variable Length Subnetting. It provides support for discontiguous networks.

Q: It's said that OSPF routing protocol exchanges are authenticated. What does this mean?

A: This means that only trusted routers can participate in the Autonomous System's routing. A single authentication scheme is used for each area. Each participating router can have a password.

Q: What is an area?

A: An area is a collection of networks together with routers having interfaces to any of the included networks.

Q: What is a stub area?

A: A stub area is an area in which you don't allow advertisements of external routes.

Q: When you define an area to be a stub area by the command "area xx stub" in every router in the stub area, do you need the "area xx default- cost yy" command in every router too?

A: No, "area-default-cost yy" is only required in area border routers.

Q: If your network has no externals, is there any benefit of using stub areas?

A: No, you don't need the "stub area" command in the router if your network has no externals.

Q: When OSPF is configured, does area 0 have to be there?

A: There is no need to have area 0 if you have only one area in your network. You can use any number as the area id. You only need area 0 to connect multiple areas if you have more than one area. But, when the autonomous is divided into areas, there has to be an area 0 which is the backbone area. The backbone must be contiguous. If the backbone is partitioned, then parts of the autonomous system will become unreachable. Virtual links can be configured to repair the partition.

Q: Could one configure an autonomous system that contained one class B network and used multiple areas with backbone area 0?

A: Yes.

Q: Can we use an area ID based on IP addresses?

A: Yes, Cisco's implementation takes area id both in IP address format and decimal number.

Q: The 9.1 documentation states that if you set def=0, therouter is ineligible to ever become the designated router. Then, two paragraphs later, it states that the default setting is 0. What does this mean?

A: This is an error in the manual. If a router's priority is 0, then it is ineligible to become a designated or backup designated router. Cisco routers have a default priority of 1.

      Ethernet 0 is up, line protocol is up
      Internet Address, Mask, Area AS       
      1099, Router ID, Network Type BROADCAST, Cost: 10 
      Transmit Delay is 1 sec, State DR, Priority 1 
      Designated Router id, Interface address No 
      backup designated router on this network Timer intervals configured, 
      Hello 10, Dead 40, Wait 40, Retransmit 5 Hello due in 0:00:09
      Neighbor Count is 0, Adjacent neighbor count is 0 

Q: There is a command to set the Link State Retransmit Interval. What is this?

A: Each newly received link state advertisement must be acknowledged. This is done by sending link state acknowledgment packets. LSAs are retransmitted until they are acknowledged. Link State Retransmit Interval defines the time between retransmissions.

Q: IP-OPSF-Transmit-Delay: What is the purpose of this variable, which adds a specified time to the age field of the update?

A: If the delay is not added before transmission over a link, the time in which the LSA propagates over the link is not considered. The default value is 1 second. This parameter has more significance on very low speed links.

Q: What is a virtual link? When and how is it used?

A: The backbone area must be contiguous; otherwise some areas of the Autonomous System will become unreachable. Virtual links establish connectivity to the backbone. The two end points of the virtual link are area border routers that both have virtual link configured. Whenever there is an area that does not have a connection to the backbone, the virtual link provides that connectivity. OSPF treats two routers joined by a virtual link as if they were connected by an unnumbered point-to-point network. Virtual links cannot be configured on unnumbered links or through stub areas.

Q: A great deal of literature suggests that OSPF is a complete solution to the problems of discontiguous addressing in IP nets. However, many people were under the impression that only the static option of the virtual link in OSPF allowed discontiguous nets regardless of the mask propogation properties of OSPF. Is this an accurate statement?

A: No. Virtual links in OSPF maintain connectivity to the backbone from non-backbone areas, but they are unnecessary for discontiguous addressing. OSPF provides support for discontiguous networks, since every area has a collection of networks and OSPF attaches a mask to each advertisement.

Q: Is there a limitation on the number of routers in an area?

A: No but this all depends on your network, available memory, processing, etc. In general, in order for OSPF to scale well, you should have less than 40 routers in an area.

Q: All advertisements are sent using multicast addressing. Are the multicast IP addresses mapped to MAC-level multicast addresses?

A: Except for Token Ring, the multicast IP addresses are mapped to MAC-level multicast addresses. Cisco maps Token Ring to MAC-level broadcast addresses.

Q: OSPF's default cost for an interface is inversely proportional to its bandwidth (10exp8 / bandwidth). But whatever "bandwidth" is configured on a given interface, the cost calculated by OSPF is the same. Why?

A: OSPF does not calculate interface costs automatically from bandwidth. The user has to set it manually using the command int e 0 ip ospf cost xx. (This depends on your level of Cisco IOS.)

Q: Does Cisco's OSPF implementation support IP TOS-based routing?

A: Cisco only supports TOS 0. This means that routers route all packets on the TOS 0 path, eliminating the need to calculate non-zero TOS paths.

Q: Does OSPF discover multiple routes to a destination?

A: Yes, it discovers multiple equal-cost routes to a destination.

Q: Will the offset-list subcommand work for OSPF, or is it only implemented for IGRP, RIP, and Hello?

A: It is only there for IGRP, RIP, and Hello. It does not work with OSPF.

Q: Can an OSPF default be originated into the system based on external information (such as routes learned from some exterior protocol) on a router which does not itself have a default?

A: OSPF will generate a default only if it is configured using the command default-information originate and if there is a default network in the box from a different process. The default route in OSPF is

Q: Can distribute-list in/out be used with OSPF to filter routes?

A: The command distribute-list IN does not work on OSPF routes. It is applied when OSPF routes are fed into the routing table. You cannot alter the database, and a link state will still be generated.

The command distribute-list OUT works only on the routes being redistributed from other processes into OSPF. It can be applied only to EXTERNAL_TYPE2 and EXTERNAL_TYPE1 routes and cannot be applied to INTRA and INTER routes.

Q: Does Cisco support the OSPF MIB definitions defined in RFC 1253?

A: Release 11.0 supports the OSPF MIB.

Q: Does Cisco's software comply with RFC 1364, "BGP OSPF Interaction"?

A: Yes.

Q: Do we have to manually setup adjacencies for routers on the SMDS cloud with the OSPF neighbor subcommand?

A: In Cisco IOS 9.1, you need the OSPF neighbor command to make OSPF work on SMDS. As of 10.0, you need the ip ospf network broadcast command on the designated router.

Q: Why must the neighbor command be used when running OSPF over NBMA (Frame Relay, X.25, etc.)?

A: You need the neighbor command to make OSPF to work on NBMA in Cisco IOS 9.1. As of 10.0, at the OSPF level, an NBMA network can be configured as a broadcast network, and OSPF would treat NBMA as a broadcast network only. You would need X.25 maps with BROADCAST keyword to make it work.

Q: Can I assume that when routes are redistributed between OSPF processes, all SPF metrics are preserved and the default metric value is not used?

A: Metrics are not preserved. The redistribution between them is like redistibution between any two IP routing processes.

Q: What do the states DR/OTHER, DR, and BDR mean in sh IP OSPF int output?

A: DR means "Designated Router," BDR means "Backup Designated Router," and DR/OTHER means a router that is neither the DR nor the BDR. DR will generated a Network Link State Advertisement representing that network, listing all the routers on that network.

Q: I have the following setup:

     ------                  ------
     | R1 |                  | R2 |
     ------\                /------
            -              -
             \ (  X.25   )/
               ( network )
             /            \
            -              -
     ------/                \------
     | R4 |                  | R3 |
     ------                  ------

R1 through R4 are running OSPF, and each router is declared as neighbor in the other three. I want to connect R5, a fifth router, to that network. Can I declare R5 as neighbor of the Designated Router only, and still get the whole routing table?

A: You need to list all the routers only in the routers eligible for DR/BDR. If you list R5 only in the present DR, you might have some problems when that DR goes down and routers are trying to become DR/BDR. If you think a router should not be allowed to become DR or BDR (its priority is set to 0), there is no need to list any routers in that router. As of Cisco IOS 10.0, Cisco routers allow these non-broadcast networks to be configured as broadcast in order to avoid all this neighbor configuration.

Q: How does Cisco accomodate OSPF routing on partial-mesh Frame Relay Networks? What about other routing protocols, like RIP and IGRP?

A: You can configure OSPF to understand whether or not it should attempt to use multicast facilities on a multi-access interface. Also, if multicast is available, OSPF will use it for its normal multicasts.

Cisco IOS 10.0 includes a feature called "subinterfaces." This feature can be used with Frame Relay and similar interfaces to tie a set of VCs together to form a virtual interface, which acts as a single IP subnet. All systems within the subnet are expected to be fully meshed. This feature is routing protocol independent. As of 10.3 and 11.0, point-to-multipoint is also available.

RIP and IGRP have had other enhancements to deal with this same situation since Cisco IOS 8.3(3).

Q: The area router subcommand associates router interfaces with OSPF areas, and it requires an address-wildmask pair. Which address-wildmask pair should be used for assigning an unnumbered interface to an area?

A: Use the address-wildmask pair of interface to which the unnumbered interface is pointing.

Section 1  Section 2  Section 3  Section 4  Section 5