What is Open Shortest Path First – OSPF?
OSPF Open Shortest Path First is a link-state routing protocol that was developed in 1991. In 1998, The current version of OSPF for IPv4 is OSPFv2 introduced in RFC 1247 and updated in RFC 2328 by John Moy. In 1999, OSPFv3 for IPv6 was published in RFC 2740.
OSPF was developed as a replacement for the distance vector routing protocol RIP. It operates as a classless routing protocol that uses the concept of areas for network scalability. RFC 2328 defines the OSPF metric as an arbitrary value called cost. The Cisco IOS uses bandwidth as the OSPF cost metric.
OSPF’s major advantages over RIP are its fast convergence and its scalability to much larger network implementations.
OSPF has a default administrative distance of 110. As a classless routing protocol, it does not use a Transport layer protocol, as OSPF packets are sent directly over IP.
OSPF Hello Packets
The OSPF Hello packet is used to establish neighbor adjacencies. By default, OSPF Hello packets are sent :
- Every 10 seconds on multi-access and point-to-point segments
- Every 30 seconds on non-broadcast multi-access (NBMA) segments (Frame Relay, X.25, ATM).
OSPF Dead Intervals
OSPF dead interval is measured as the period of time an OSPF router will wait before terminating adjacency with a neighbor. The Dead interval is four times the Hello interval, by default.
- For multi-access and point-to-point segments, this period is 40 seconds.
- For NBMA networks, the Dead interval is 120 seconds.
For routers to become adjacent, their Hello interval, Dead interval, Network types and subnet masks must match.
OSPF Router IDs
The OSPF router ID is used to exclusively identify each router in the OSPF routing domain. Cisco routers derive the router ID based on three criteria and with the following preference:
- the Use of the IP address configured with the OSPF router ID command.
- If the router ID is not configured, the router chooses highest IP address of any of its loopback interfaces.
- If no loopback interfaces are configured, the router chooses highest active IP address of any of its physical interfaces.
OSPF Area IDs
The area ID refers to the OSPF network domain area. An OSPF area is a group of routers that share link-state information. All OSPF routers in the same domain area must have the same link-state information – received from neighbours – in their link-state databases.
In a typical OSPF design, routers are connected to a backbone called area 0 or backbone area.OSPF design must have a backbone area and other routers must connect to this area, this can also be refered to as OSPF Multi-Area.
Open Shortest Path First (OSPF) is a popular routing protocol for IP networks for several key reasons:-
* It is classless,
* Offers full CIDR and VLSM support,
* It scales well, converges quickly, and guarantees loop free routing.
It also supports address summarization and the tagging of external routes, similar to EIGRP.
OSPF uses a large, dimensionless metric on every link – which can also be referred to as “cost – , with a maximum value of 65,535. It is important to remember that OSPF doesn’t add these metrics the same way that RIP and EIGRP do.
In those protocols, each router updates the total metric as it passes the route on to the next router. However, in OSPF, the routers distribute the individual link costs to one another.
The maximum cost for an individual link, then, is 65,535. Any given path through an OSPF network can include many high-cost links, but still be usable. This is quite different from RIP, for example, where a few high-cost links along a path can make the entire path unusable.
Basic OSPF Configuration
How to Configure OSPF Multiarea network.