
The TCP/IP Guide - Version 3.0 (Contents) ` 741 _ © 2001-2005 Charles M. Kozierok. All Rights Reserved.
In this example, Router A and Router D are internal routers. Router B and Router C are
area border routers, and comprise the backbone (Area 0) of the internetwork. Routers A, B
and C will maintain an LSDB describing Area 1, while Routers B, C and D will maintain an
LSDB describing Area 2. Routers B and C maintain a separate LSDB for the backbone.
There is no backbone router other than the area border routers B and C. However, suppose
we had a router E that had only direct connections to RB and RC. This would be a
backbone router only.
You have probably already discovered the chief drawback to hierarchical topology:
complexity. For large autonomous systems, however, it has significant advantages over
making every router a peer. At the same time, the conceptual complexity is made worse by
the need for very careful design, especially of the backbone. If the hierarchy is not set up
properly, a single failure of a link between routers could disrupt the backbone and isolate
one or more of the areas (including all the devices on all networks within the area!)
OSPF Route Determination Using SPF Trees
The key data structure maintained by each router in an OSPF autonomous system (AS) is
the link-state database (LSDB). The LSDB contains a representation of the topology of
either the entire AS (in basic topology) or a single area (in hierarchical topology). As we
have seen earlier in this section, each router in the AS or area has the same LSDB, so it
represents a neutral view of the connections between routers and networks.
Of course, each router needs to participate in keeping the LSDB up to date, but it also has
its own “selfish” concerns. It needs to be able to determine what routes it should use for
datagrams it receives from its connected networks—this is, after all, the entire point of a
routing protocol.
The SPF Tree
To find the best route from any router, it must determine the shortest path between itself and
each router or network in the AS or area. For this, it needs not a neutral view of the inter-
network but a view of it from its own perspective.
The router creates this perspective by taking the information in the LSDB and transforming
it into a shortest path first tree or SPF tree. The term “tree” refers to a data structure with a
root that has branches coming out that go to other nodes, which in turn have branches. The
structure as a whole looks like an upside-down tree. In this case, the SPF tree shows the
topology information of the AS or area with the router constructing the tree at the top. Each
directly-connected router or network is one step down in the tree; each router or network
connected to these first-level routers or networks is then connected, and so on, until the
entire AS or area has been represented.
Again, the router doesn't really make the tree; it is just an algorithmic calculation performed
by the computer within the router. Once this is done, however, this logical construct can be
used to calculate the cost for that router to reach any router or network in the AS (or area).
In some cases, there may be more than one way to reach a router or network, so the tree is
constructed to show only the shortest (lowest-cost) path to the network.