Skip to Content
IP Routing
book

IP Routing

by Ravi Malhotra
January 2002
Beginner
238 pages
6h 20m
English
O'Reilly Media, Inc.
Content preview from IP Routing

OSPF Metric

Each OSPF router executes Dijkstra’s SPF algorithm to compute the shortest-path tree from itself to every subnetwork in its area. However, RFC 2328 does not specify how a router should compute the cost of an attached network -- this is left to the vendor. Cisco computes the cost of an attached network as follows:

Cost = 108/bandwidth of interface in bits per second

Using this definition, the OSPF cost for some common media types is shown in Table 6-1. Table 6-1 assumes default interface bandwidth. Note that the cost is rounded down to the nearest integer.

Table 6-1. Default OSPF costs

Media type

Default bandwidth

Default OSPF cost

Ethernet

10 Mbps

10

Fast Ethernet

100 Mbps

1

FDDI

100 Mbps

1

T-1 (serial interface)[a]

1,544 kbps

64

56 kbps (serial interface)

1,544 kbps

64

HSSI

45,045 kbps

2

[a] All serial interfaces on Cisco routers are configured with the same default bandwidth (1,544 kbits/s) and delay (20,000 ms) parameters.

The OSPF cost computed by a router can be checked with the command show ip ospf interface , as in line 4 in the code block in the previous section, where the cost of the Ethernet segment is 10. The composite cost of reaching a destination is the sum of the individual costs of all networks in the path to the destination and can be seen as output of the show ip route command in lines 6, 7, and 8.

The default value of the OSPF metric may not be adequate in some situations. For example, in TraderMary’s configuration, the NewYork ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

IP Routing Protocols

IP Routing Protocols

Uyless Black
Network Routing, 2nd Edition

Network Routing, 2nd Edition

Deep Medhi, Karthik Ramasamy
Troubleshooting IP Routing Protocols

Troubleshooting IP Routing Protocols

Faraz Shamim, Zaheer Aziz, Johnson Liu, Abe Martey

Publisher Resources

ISBN: 0596002750Catalog PageErrata