Mr.Chan

导航

OSPF 数据库问题


 Appendix A: Link-State Database Synchronization

 

In the above diagram, routers on the same segment go through a series of states before forming a successful adjacency. The neighbor and DR election are done via the Hello protocol. Whenever a router sees itself in his neighbor's Hello packet, the state transitions to "2-Way". At that point DR and BDR election is performed on multi-access segments. A router continues forming an adjacency with a neighbor if either of the two routers is a DR or BDR or they are connected via a point-to-point or virtual link.

In the Exstart state,the two neighbors form a Master/Slave relationship where they agree on a initial sequence number. The sequence number is used to detect old or duplicate Link-State Advertisements (LSA).

In the Exchange state, Database Description Packets (DD) will get exchanged. These are abbreviated link-state advertisements in the form of link-state headers. The header supplies enough information to identify a link. The master node sends DD packets which are acknowledged with DD packets from the slave node. All adjacencies in exchange state or greater are used by the flooding procedure. These adjacencies are fully capable of transmitting and receiving all types of OSPF routing protocol packets.

In the Loading state, link-state request packets are sent to neighbors, asking for more recent advertisements that have been discovered but not yet received. Each router builds a list of required LSAs to bring its adjacency up to date. A Retransmission List is maintained to make sure that every LSA is acknowledged. To specify the number of seconds between link-state advertisement retransmissions for the adjacency you can use:

ip ospf retransmit-interval seconds.

Link-state update packets are sent in response to request packets. The link-state update packets will be flooded over all adjacencies.

In the Full state, the neighbor routers are fully adjacent. The databases for a common area are an exact match between adjacent routers.

Each LSA has an age field that gets periodically incremented while it is contained in the database or as it gets flooded throughout the area. When an LSA reaches a Maxage it gets flushed from the database if that LSA is not on any neighbors retransmission list.

Link-State Advertisements

Link-state advertisements are broken into five types. Router Links (RL) are generated by all routers. These links describe the state of the router interfaces inside a particular area. These links are only flooded inside the router's area. Network Links (NL) are generated by a DR of a particular segment; these are an indication of the routers connected to that segment. Summary Links (SL) are the inter-area links (type 3); these links will list the networks inside other areas but still belonging to the autonomous system. Summary links are injected by the ABR from the backbone into other areas and from other areas into the backbone. These links are used for aggregation between areas. Other types of summary links are the asbr-summary links. These are type 4 links that point to the ASBR. This is to make sure that all routers know the way to exit the autonomous system. The last type is type 5, External Links (EL), these are injected by the ASBR into the domain.

The above diagram illustrates the different link types. RTA generates a router link (RL) into area 1, and it also generates a network link (NL) since it happens the be the DR on that particular segment. RTB is an ABR, and it generates RL into area 1 and area 0. RTB also generates summary links into area 1 and area 0. These links are the list of networks that are interchanged between the two areas. An ASBR summary link is also injected by RTB into area 1. This is an indication of the existence of RTD, the autonomous system border router. Similarly RTC, which is another ABR, generates RL for area 0 and area 2, and a SL (3) into area 2 (since it is not announcing any ASBR), and a SL (3,4) into area 0 announcing RTD. RTD generates a RL for area 2 and generates an EL for external routes learned via BGP. The external routers will be flooded all over the domain.

The following table is a summary of the link state advertisements.

LS Type

Advertisement Description

1

Router Link advertisements. Generated by each router for each area it belongs to. They describe the states of the router's link to the area. These are only flooded within a particular area.

2

Network Link advertisements. Generated by Designated Routers. They describe the set of routers attached to a particular network. Flooded in the area that contains the network.

3 or 4

Summary Link advertisements. Generated by Area Border routers. They describe inter-area (between areas) routes. Type 3 describes routes to networks, also used for aggregating routes. Type 4 describes routes to ASBR.

5

AS external link advertisements. Originated by ASBR. They describe routes to destinations external to the AS. Flooded all over except stub areas.


If you look at the OSPF database in detail, using show ip ospf database detail, you will see different keywords such as Link-Data, Link-ID, and Link-state ID. These terms become confusing as the value of each depends on the link state type and the link-type. We will go over this terminology and will provide a detailed example on the OSPF database as seen from the router.

The Link-State ID basically defines the identity of the link-state depending on the LS type. Router Links are identified by the router ID (RID) of the router that originated the advertisement. Network Links are identified by the relative IP address of the DR. This makes sense because Network Links are originated by the Designated Router. Summary Links (type 3) are identified by the IP network numbers of the destinations they are pointing at. ASBR Summary Links (Summary Links type 4) are identified by the RID of the ASBR. Finally, External Links are identified by the IP network numbers of the external destinations they are pointing at. The following table summarizes this information:

LS Type

Link State ID
(In the high level view of the database when referencing a router this is called Link ID)

1

The originating Router's Router ID (RID).

2

The IP interface address of the network's Designated Router.

3

The destination network number.

4

The router ID of the described AS boundary router.

5

The external network number.


Next, we will describe the different links available:

Stub network links: This term has nothing to do with stub areas. A stub segment is a segment that has one router only attached to it. An Ethernet or Token Ring segment that has one attached router is considered a link to a stub network. A loopback interface is also considered a link to stub network with a 255.255.255.255 mask (Host route).

Point-to-point links: These could be physical or logical (subinterfaces) point-to-point serial link connections. These links could be numbered (an IP address is configured on the link) or unnumbered.

Transit links: These are interfaces connected to networks that have more than one router attached, hence the name transit.

Virtual links: These are logical links that connect areas that do not have physical connections to the backbone. Virtual links are treated as numbered point-to-point links.

The link-ID is an identification of the link itself. This is different for each link type. A transit link is identified by the IP address of the DR on that link. A numbered point-to-point link is identified by the RID of the neighbor router on the point-to-point link. Virtual links are identical to point-to-point links. Finally, links to stub networks are identified by the IP address of the interface to the stub network. The following table summarizes this information:

Link Type

Link ID
(This applies to individual Links)

Point-to-Point

Neighbor Router ID

Link to transit network

Interface address of DR

Link to stub network
(In case of loopback mask is 255.255.255.255)

Network/subnet number

Virtual Link

Neighbor Router ID


The Link Data is the IP address of the link, except for stub network where the link data is the network mask.

Link Type

Link Data

Stub network

Network Mask

Other networks (applies to router links only)

Router's associated IP interface address


Finally, an Advertising Router is the RID of the router that has sent the LSA.

OSPF Database Example

Given the network diagram above, the following configurations, and the IP route tables, let us look at different ways of understanding the OSPF database.

 RTA#

 interface Loopback0

  ip address 203.250.13.41 255.255.255.255

 

 interface Ethernet0

  ip address 203.250.15.68 255.255.255.192

 

 interface Ethernet1

  ip address 203.250.15.193 255.255.255.192

 

 router ospf 10

  network 203.250.0.0 0.0.255.255 area 0

 

 RTA#show ip route

 Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

        D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

        E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

        i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default

 

 Gateway of last resort is 203.250.15.67 to network 0.0.0.0

 

      203.250.16.0 255.255.255.192 is subnetted, 1 subnets

 O E2    203.250.16.128 [110/10] via 203.250.15.67, 00:00:50, Ethernet0

      203.250.13.0 255.255.255.255 is subnetted, 1 subnets

 C       203.250.13.41 is directly connected, Loopback0

      203.250.15.0 255.255.255.192 is subnetted, 3 subnets

 O IA    203.250.15.0 [110/74] via 203.250.15.67, 00:00:50, Ethernet0

 C       203.250.15.64 is directly connected, Ethernet0

 C       203.250.15.192 is directly connected, Ethernet1

 O*E2 0.0.0.0 0.0.0.0 [110/10] via 203.250.15.67, 00:00:50, Ethernet0

 

 RTE#

 ip subnet-zero

 

 interface Ethernet0

  ip address 203.250.16.130 255.255.255.192

 

 interface Serial0

  ip address 203.250.15.2 255.255.255.192

 

 router ospf 10

  redistribute rip metric 10 subnets

  network 203.250.15.0 0.0.0.63 area 1

  default-information originate metric 10

 

 router rip

  network 203.250.16.0

 

 ip route 0.0.0.0 0.0.0.0 Ethernet0

 

RTE#show ip route

 Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

        D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

        E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

        i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default

 

 Gateway of last resort is 0.0.0.0 to network 0.0.0.0

 

      203.250.16.0 255.255.255.192 is subnetted, 1 subnets

 C       203.250.16.128 is directly connected, Ethernet0

      203.250.13.0 is variably subnetted, 2 subnets, 2 masks

 O IA    203.250.13.41 255.255.255.255

            [110/75] via 203.250.15.1, 00:16:31, Serial0

      203.250.15.0 255.255.255.192 is subnetted, 3 subnets

 C       203.250.15.0 is directly connected, Serial0

 O IA    203.250.15.64 [110/74] via 203.250.15.1, 00:16:31, Serial0

 O IA    203.250.15.192 [110/84] via 203.250.15.1, 00:16:31, Serial0

 S*   0.0.0.0 0.0.0.0 is directly connected, Ethernet0

 

 RTC#

 ip subnet-zero

 

 interface Ethernet0

  ip address 203.250.15.67 255.255.255.192

 

 interface Serial1

  ip address 203.250.15.1 255.255.255.192

 

 router ospf 10

  network 203.250.15.64 0.0.0.63 area 0

  network 203.250.15.0 0.0.0.63 area 1

 

RTF#show ip route

 Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

        D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

        E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

        i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default

 

 Gateway of last resort is 203.250.15.2 to network 0.0.0.0

 

      203.250.16.0 255.255.255.192 is subnetted, 1 subnets

 O E2    203.250.16.128 [110/10] via 203.250.15.2, 04:49:05, Serial1

      203.250.13.0 255.255.255.255 is subnetted, 1 subnets

 O       203.250.13.41 [110/11] via 203.250.15.68, 04:49:06, Ethernet0

      203.250.15.0 255.255.255.192 is subnetted, 3 subnets

 C       203.250.15.0 is directly connected, Serial1

 C       203.250.15.64 is directly connected, Ethernet0

 O       203.250.15.192 [110/20] via 203.250.15.68, 04:49:06, Ethernet0

 O*E2 0.0.0.0 0.0.0.0 [110/10] via 203.250.15.2, 04:49:06, Serial1

General View of the Database

RTC#show ip ospf database

 

       OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                Router Link States (Area 1)

 

Link ID         ADV Router      Age    Seq#       Checksum Link count

203.250.15.67   203.250.15.67   48     0x80000008 0xB112   2

203.250.16.130  203.250.16.130  212    0x80000006 0x3F44   2

 

                Summary Net Link States (Area 1)

 

Link ID         ADV Router      Age    Seq#       Checksum

203.250.13.41   203.250.15.67   602    0x80000002 0x90AA

203.250.15.64   203.250.15.67   620    0x800000E9 0x3E3C

203.250.15.192  203.250.15.67   638    0x800000E5 0xA54E

 

                Router Link States (Area 0)

 

Link ID         ADV Router      Age    Seq#       Checksum Link count

203.250.13.41   203.250.13.41   179    0x80000029 0x9ADA   3

203.250.15.67   203.250.15.67   675    0x800001E2 0xDD23   1

 

                Net Link States (Area 0)

 

Link ID         ADV Router      Age    Seq#       Checksum

203.250.15.68   203.250.13.41   334    0x80000001 0xB6B5

 

                Summary Net Link States (Area 0)

 

Link ID         ADV Router      Age    Seq#       Checksum

203.250.15.0    203.250.15.67   792    0x80000002 0xAEBD

 

                Summary ASB Link States (Area 0)

 

Link ID         ADV Router      Age    Seq#       Checksum

203.250.16.130  203.250.15.67   579    0x80000001 0xF9AF

 

                AS External Link States

 

Link ID         ADV Router      Age    Seq#       Checksum Tag

0.0.0.0         203.250.16.130  1787   0x80000001 0x98CE   10

203.250.16.128  203.250.16.130  5      0x80000002 0x93C4   0

This is a general look at the whole OSPF database. The database is listed according to the areas. In this case, we are looking at RTC's database which is an ABR. Both area 1 and area 0's databases are listed. Area 1 is composed of router links and summary links. No network links exist because no DR exists on any of the segments in area 1. No Summary ASBR links exist in area 1 because the only ASBR happens to be in area 0. External links do not belong to any particular area as they are flooded all over. Note that all the links are the cumulative links collected from all routers in an area.

We will mainly concentrate on the database in area 0. The Link-ID indicated here is actually the Link-State ID. This is a representation of the whole router, not a particular link. This is a bit confusing, but just remember that this high level Link-ID (should be Link-State ID) represents the whole router and not just a link.

Router Links

                 Router Link States (Area 0)

 

 Link ID         ADV Router      Age    Seq#       Checksum Link count

 203.250.13.41   203.250.13.41   179    0x80000029 0x9ADA   3

 203.250.15.67   203.250.15.67   675    0x800001E2 0xDD23   1

We will start with the router links. There are two entries listed for 203.250.13.41 and 203.250.15.67, these are the RIDs of the two routers in area 0. The number of links in area 0 for each router is also indicated. RTA has three links to area 0 and RTC has one link. A detailed view of RTC's router links follows:

RTC#show ip ospf database router 203.250.15.67

 

     OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                Router Link States (Area 1)

 

  LS age: 1169

  Options: (No TOS-capability)

  LS Type: Router Links

  Link State ID: 203.250.15.67

  Advertising Router: 203.250.15.67

  LS Seq Number: 80000008

  Checksum: 0xB112

  Length: 48

  Area Border Router

   Number of Links: 2

 

    Link connected to: another Router (point-to-point)

     (Link ID) Neighboring Router ID: 203.250.16.130

     (Link Data) Router Interface address: 203.250.15.1

      Number of TOS metrics: 0

       TOS 0 Metrics: 64

 

    Link connected to: a Stub Network

     (Link ID) Network/subnet number: 203.250.15.0

     (Link Data) Network Mask: 255.255.255.192

      Number of TOS metrics: 0

       TOS 0 Metrics: 64

One thing to note here is that OSPF generates an extra stub link for each point-to-point interface. Do not get confused if you see the link count larger than the number of physical interfaces.

                 Router Link States (Area 0)

 

  LS age: 1227

  Options: (No TOS-capability)

  LS Type: Router Links

  Link State ID: 203.250.15.67

  Advertising Router: 203.250.15.67

  LS Seq Number: 80000003

  Checksum: 0xA041

  Length: 36

  Area Border Router

   Number of Links: 1

 

    Link connected to: a Transit Network

     (Link ID) Designated Router address: 203.250.15.68

     (Link Data) Router Interface address: 203.250.15.67

      Number of TOS metrics: 0

       TOS 0 Metrics: 10

Note that the Link ID is equal to the IP address (not the RID) of the attached DR; in this case it is 203.250.15.68. The Link Data is RTC's own IP address.

Network Links

                Net Link States (Area 0)

Link ID         ADV Router      Age    Seq#       Checksum

203.250.15.68   203.250.13.41   334    0x80000001 0xB6B5

One network link is listed, indicated by the interface IP address (not the RID) of the DR, in this case 203.250.15.68. A detailed view of this entry follows:

RTC#show ip ospf database network

 

       OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                Net Link States (Area 0)

 

  Routing Bit Set on this LSA

  LS age: 1549

  Options: (No TOS-capability)

  LS Type: Network Links

  Link State ID: 203.250.15.68 (address of Designated Router)

  Advertising Router: 203.250.13.41

  LS Seq Number: 80000002

  Checksum: 0xB4B6

  Length: 32

  Network Mask: 255.255.255.192

 

        Attached Router: 203.250.13.41

        Attached Router: 203.250.15.67

Note that the network link lists the RIDs of the routers attached to the transit network; in this case the RIDs of RTA and RTC are listed.

Summary Links

                  Summary Net Link States (Area 0)

 

Link ID         ADV Router      Age    Seq#       Checksum

203.250.15.0    203.250.15.67   792    0x80000002 0xAEBD

Area 0 has one summary link represented by the IP network address of the

link 203.250.15.0. This link was injected by the ABR RTC from area 1 into

area 0. A detailed view of this summary link follows, summary links for

area 1 are not listed here:

 

RTC#show ip ospf database summary (area 1 is not listed)

 

              Summary Net Link States (Area 0)

 

  LS age: 615

  Options: (No TOS-capability)

  LS Type: Summary Links(Network)

  Link State ID: 203.250.15.0 (summary Network Number)

  Advertising Router: 203.250.15.67

  LS Seq Number: 80000003

  Checksum: 0xACBE

  Length: 28

  Network Mask: 255.255.255.192 TOS: 0  Metric: 64

Summary ASBR Links

                Summary ASB Link States (Area 0)

 

Link ID         ADV Router      Age    Seq#       Checksum

203.250.16.130  203.250.15.67   579    0x80000001 0xF9AF

This is an indication of who the ASBR is. In this case the ASBR is RTE represented by its RID 203.250.16.130. The advertising router for this entry into area 0 is RTC with RID 203.250.15.67. A detailed view of the summary ASBR entry follows:

RTC#show ip ospf database asbr-summary

 

        OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                 Summary ASB Link States (Area 0)

 

   LS age: 802

   Options: (No TOS-capability)

   LS Type: Summary Links(AS Boundary Router)

   Link State ID: 203.250.16.130 (AS Boundary Router address)

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000003

   Checksum: 0xF5B1

   Length: 28

   Network Mask: 0.0.0.0 TOS: 0  Metric: 64

External Links

                AS External Link States

 

Link ID         ADV Router      Age    Seq#       Checksum Tag

0.0.0.0         203.250.16.130  1787   0x80000001 0x98CE   10

203.250.16.128  203.250.16.130  5      0x80000002 0x93C4   0

We have two external Links, the first one is the 0.0.0.0 injected into OSPF via t he default-information originate command. The other entry is network 203.250.16.12 8 which is injected into OSPF by redistribution. The router advertising these networks is 203.250.16.130, the RID of RTE. The following is the detailed view of the external routes:

RTC#show ip ospf database external

 

        OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                 AS External Link States

 

   Routing Bit Set on this LSA

   LS age: 208

   Options: (No TOS-capability)

   LS Type: AS External Link

   Link State ID: 0.0.0.0 (External Network Number )

   Advertising Router: 203.250.16.130

   LS Seq Number: 80000002

   Checksum: 0x96CF

   Length: 36

   Network Mask: 0.0.0.0

         Metric Type: 2 (Larger than any link state path)

         TOS: 0

         Metric: 10

         Forward Address: 0.0.0.0

         External Route Tag: 10

 

  Routing Bit Set on this LSA

   LS age: 226

   Options: (No TOS-capability)

   LS Type: AS External Link

   Link State ID: 203.250.16.128 (External Network Number)

   Advertising Router: 203.250.16.130

   LS Seq Number: 80000002

   Checksum: 0x93C4

   Length: 36

   Network Mask: 255.255.255.192

         Metric Type: 2 (Larger than any link state path)

         TOS: 0

         Metric: 10

         Forward Address: 0.0.0.0

         External Route Tag: 0

Note the forward address. Whenever this address is 0.0.0.0 it indicates that the external routes are reachable via the advertising router, in this case 203. 250.16.130. This is why the identity of the ASBR is injected by ABRs into other areas using ASBR summary links.

This forward address is not always 0.0.0.0. In some cases, it could be the IP address of another router on the same segment. The following diagram will illustrate this situation:

In the above situation RTB, is running BGP with RTA, and OSPF with the rest of the domain. RTA is not running OSPF. RTB is redistributing BGP routes into OSPF. According to OSPF, RTB is an ASBR advertising external routes. The forwarding address in this case is set to 125.211.1.1 and not to the advertising router (0.0.0.0) RT B. This makes sense because there is no need to make the extra hop. An important thing to remember is that routers inside the OSPF domain should be able to reach the forwarding address via OSPF in order for the external routes to be put in the IP routing table. If the forwarding address is reached via some other protocol or no t accessible, the external entries would be in the database but not in the IP routing table.

Another situation would arise if both RTB and RTC are ASBRs (RTC is also running BGP with RTA). In this situation, in order to eliminate the duplication of the effort, one of the two routers will not advertise (will flush) the external routes. T he router with the higher RID will win.

The Full Database

Finally, this is a listing of the whole database as an exercise. You should now b e able to go over each entry and explain what is going on:

 RTC#show ip ospf database router

 

         OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                 Router Link States (Area 1)

 

   LS age: 926

   Options: (No TOS-capability)

   LS Type: Router Links

   Link State ID: 203.250.15.67

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000035

   Checksum: 0x573F

   Length: 48

   Area Border Router

    Number of Links: 2

 
    Link connected to: another Router (point-to-point)

      (Link ID) Neighboring Router ID: 203.250.16.130

      (Link Data) Router Interface address: 203.250.15.1

       Number of TOS metrics: 0

        TOS 0 Metrics: 64

     Link connected to: a Stub Network

      (Link ID) Network/subnet number: 203.250.15.0

      (Link Data) Network Mask: 255.255.255.192

       Number of TOS metrics: 0

        TOS 0 Metrics: 64

 

   Routing Bit Set on this LSA

   LS age: 958

   Options: (No TOS-capability)

   LS Type: Router Links

   Link State ID: 203.250.16.130

   Advertising Router: 203.250.16.130

   LS Seq Number: 80000038

   Checksum: 0xDA76

   Length: 48

   AS Boundary Router

    Number of Links: 2

 

     Link connected to: another Router (point-to-point)

      (Link ID) Neighboring Router ID: 203.250.15.67

      (Link Data) Router Interface address: 203.250.15.2

       Number of TOS metrics: 0

        TOS 0 Metrics: 64

 

     Link connected to: a Stub Network

      (Link ID) Network/subnet number: 203.250.15.0

      (Link Data) Network Mask: 255.255.255.192

       Number of TOS metrics: 0

        TOS 0 Metrics: 64

 

                 Router Link States (Area 0)

 

   Routing Bit Set on this LSA

   LS age: 1107

   Options: (No TOS-capability)

   LS Type: Router Links

   Link State ID: 203.250.13.41

   Advertising Router: 203.250.13.41

   LS Seq Number: 8000002A

   Checksum: 0xC0B0

   Length: 60

   AS Boundary Router

    Number of Links: 3

 

     Link connected to: a Stub Network

      (Link ID) Network/subnet number: 203.250.13.41

      (Link Data) Network Mask: 255.255.255.255

       Number of TOS metrics: 0

        TOS 0 Metrics: 1

 

     Link connected to: a Stub Network

      (Link ID) Network/subnet number: 203.250.15.192

      (Link Data) Network Mask: 255.255.255.192

       Number of TOS metrics: 0

        TOS 0 Metrics: 10

 

     Link connected to: a Transit Network

      (Link ID) Designated Router address: 203.250.15.68

      (Link Data) Router Interface address: 203.250.15.68

       Number of TOS metrics: 0

        TOS 0 Metrics: 10

 

   LS age: 1575

   Options: (No TOS-capability)

   LS Type: Router Links

   Link State ID: 203.250.15.67

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000028

   Checksum: 0x5666

   Length: 36

   Area Border Router

    Number of Links: 1

 

     Link connected to: a Transit Network

      (Link ID) Designated Router address: 203.250.15.68

      (Link Data) Router Interface address: 203.250.15.67

       Number of TOS metrics: 0

        TOS 0 Metrics: 10

 

 RTC#show ip ospf database network

 

        OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                 Net Link States (Area 0)

 

   Routing Bit Set on this LSA

   LS age: 1725

   Options: (No TOS-capability)

   LS Type: Network Links

   Link State ID: 203.250.15.68 (address of Designated Router)

   Advertising Router: 203.250.13.41

   LS Seq Number: 80000026

   Checksum: 0x6CDA

   Length: 32

   Network Mask: 255.255.255.192

         Attached Router: 203.250.13.41

         Attached Router: 203.250.15.67

 

 RTC#show ip ospf database summary

 

        OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                 Summary Net Link States (Area 1)

 

   LS age: 8

   Options: (No TOS-capability)

   LS Type: Summary Links(Network)

   Link State ID: 203.250.13.41 (summary Network Number)

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000029

   Checksum: 0x42D1

   Length: 28

   Network Mask: 255.255.255.255 TOS: 0  Metric: 11

 

   LS age: 26

   Options: (No TOS-capability)

   LS Type: Summary Links(Network)

   Link State ID: 203.250.15.64 (summary Network Number)

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000030

   Checksum: 0xB182

   Length: 28

   Network Mask: 255.255.255.192 TOS: 0  Metric: 10

 

   LS age: 47

   Options: (No TOS-capability)

   LS Type: Summary Links(Network)

   Link State ID: 203.250.15.192 (summary Network Number)

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000029

   Checksum: 0x1F91

   Length: 28

   Network Mask: 255.255.255.192 TOS: 0  Metric: 20

 

                 Summary Net Link States (Area 0)

 

   LS age: 66

   Options: (No TOS-capability)

   LS Type: Summary Links(Network)

   Link State ID: 203.250.15.0 (summary Network Number)

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000025

   Checksum: 0x68E0

   Length: 28

   Network Mask: 255.255.255.192 TOS: 0  Metric: 64

 

 RTC#show ip ospf asbr-summary

 

        OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                 Summary ASB Link States (Area 0)

 

   LS age: 576

   Options: (No TOS-capability)

   LS Type: Summary Links(AS Boundary Router)

   Link State ID: 203.250.16.130 (AS Boundary Router address)

   Advertising Router: 203.250.15.67

   LS Seq Number: 80000024

   Checksum: 0xB3D2

   Length: 28

   Network Mask: 0.0.0.0 TOS: 0  Metric: 64

 

 

 RTC#show ip ospf database external

 

       OSPF Router with ID (203.250.15.67) (Process ID 10)

 

                 AS External Link States

 

   Routing Bit Set on this LSA

   LS age: 305

   Options: (No TOS-capability)

   LS Type: AS External Link

   Link State ID: 0.0.0.0 (External Network Number)

   Advertising Router: 203.250.16.130

   LS Seq Number: 80000001

   Checksum: 0x98CE

   Length: 36

   Network Mask: 0.0.0.0

         Metric Type: 2 (Larger than any link state path)

         TOS: 0

         Metric: 10

         Forward Address: 0.0.0.0

         External Route Tag: 10

 

   Routing Bit Set on this LSA

   LS age: 653

   Options: (No TOS-capability)

   LS Type: AS External Link

   Link State ID: 203.250.16.128 (External Network Number)

   Advertising Router: 203.250.16.130

   LS Seq Number: 80000024

   Checksum: 0x4FE6

   Length: 36

   Network Mask: 255.255.255.192

         Metric Type: 2 (Larger than any link state path)

         TOS: 0

         Metric: 10

         Forward Address: 0.0.0.0

         External Route Tag: 0

Appendix B: OSPF and IP Multicast Addressing

OSPF used IP multicast to exchange Hello packets and Link State Updates. An IP multicast address is implemented using class D addresses. A class D address ranges from 224.0.0.0 to 239.255.255.255.

Some special IP multicast addresses are reserved for OSPF:

  • 224.0.0.5: All OSPF routers should be able to transmit and listen to this address.
  • 224.0.0.6: All DR and BDR routers should be able to transmit and listen to this address.

The mapping between IP multicast addresses and MAC addresses has the following rule:

For multiaccess networks that support multicast, the low order 23 bits of the IP address are used as the low order bits of the MAC multicast address 01-005E-00-00- 00. For example:

·                 224.0.0.5 would be mapped to 01-00-5E-00-00-05

·                 224.0.0.6 would be mapped to 01-00-5E-00-00-06.

OSPF uses broadcast on Token Ring networks.

 

posted on 2005-05-22 16:29  cunshen  阅读(883)  评论(0)    收藏  举报