Installing and Administering Internet Services

274 Chapter 8
Configuring gated
Configuring the OSPF Protocol
Cost
The outbound side of each router interface is associated with a
configurable cost. Lower cost interfaces are more likely to be used in
forwarding data traffic. Cost values are assigned at the discretion of the
network or system administrator. While the value is arbitrary, it should
be a function of throughput or capacity of the interface: the higher the
value, the lower the throughput or capacity. Thus, the interfaces with the
highest throughput or capacity should be assigned lower cost values than
other interfaces. Interfaces from networks to routers have a cost of 0.
Figure 8-12 shows an example network where costs have been specified
for each interface.
Figure 8-12 Cost Configuration Example
In Figure 8-12, there are two possible packet routes between nodes A and
D: one route goes through node B and the other route goes through node
C. The cost of each route is calculated as follows:
Node A to node B and node B to node D: 5+5 = 10
Node A to node C and node C to node D: 5+10 = 15
A
D
B C
193.2.1.33 (cost 5)
193.2.1.17 (cost 5)
193.2.1.30 (cost 10)
193.2.1.46 (cost 10)
193.2.1.35 (cost 5)
193.2.1.20 (cost 5)
LAN 1 193.2.1.32
LAN 2 193.2.1.16