Connected: An Internet Encyclopedia
12.4.1. Router links

Up: Connected: An Internet Encyclopedia
Up: Requests For Comments
Up: RFC 1583
Up: 12. Link State Advertisements
Up: 12.4. Originating link state advertisements
Prev: 12.4. Originating link state advertisements
Next: 12.4.2. Network links

12.4.1. Router links

12.4.1. Router links

A router originates a router links advertisement for each area that it belongs to. Such an advertisement describes the collected states of the router's links to the area. The advertisement is flooded throughout the particular area, and no further.

                  ....................................
                  . 192.1.2                   Area 1 .
                  .     +                            .
                  .     |                            .
                  .     | 3+---+1                    .
                  .  N1 |--|RT1|-----+               .
                  .     |  +---+                    .
                  .     |                _______N3  .
                  .     +               /          .  1+---+
                  .                     * 192.1.1 *------|RT4|
                  .     +               /_______/   .   +---+
                  .     |              /     |       .
                  .     | 3+---+1     /      |       .
                  .  N2 |--|RT2|-----+      1|       .
                  .     |  +---+           +---+8    .         6+---+
                  .     |                  |RT3|----------------|RT6|
                  .     +                  +---+     .          +---+
                  . 192.1.3                  |2      .   18.10.0.6|7
                  .                          |       .            |
                  .                   +------------+ .
                  .                     192.1.4 (N4) .
                  ....................................

                    Figure 15: Area 1 with IP addresses shown

The format of a router links advertisement is shown in Appendix A (Section A.4.2). The first 20 bytes of the advertisement consist of the generic link state advertisement header that was discussed in Section 12.1. Router links advertisements have LS type = 1. The router indicates whether it is willing to calculate separate routes for each IP TOS by setting (or resetting) the T-bit of the link state advertisement's Options field.

A router also indicates whether it is an area border router, or an AS boundary router, by setting the appropriate bits (bit B and bit E, respectively) in its router links advertisements. This enables paths to those types of routers to be saved in the routing table, for later processing of summary link advertisements and AS external link advertisements. Bit B should be set whenever the router is actively attached to two or more areas, even if the router is not currently attached to the OSPF backbone area. Bit E should never be set in a router links advertisement for a stub area (stub areas cannot contain AS boundary routers). In addition, the router sets bit V in its router links advertisement for Area A if and only if it is the endpoint of an active virtual link using Area A as its Transit area. This enables the other routers attached to Area A to discover whether the area supports any virtual links (i.e., is a transit area).

The router links advertisement then describes the router's working connections (i.e., interfaces or links) to the area. Each link is typed according to the kind of attached network. Each link is also labelled with its Link ID. This Link ID gives a name to the entity that is on the other end of the link. Table 18 summarizes the values used for the Type and Link ID fields.

                   Link type   Description       Link ID
                   __________________________________________________
                   1           Point-to-point    Neighbor Router ID
                               link
                   2           Link to transit   Interface address of
                               network           Designated Router
                   3           Link to stub      IP network number
                               network
                   4           Virtual link      Neighbor Router ID

                           Table 18: Link descriptions in the
                              router links advertisement.

In addition, the Link Data field is specified for each link. This field gives 32 bits of extra information for the link. For links to transit networks, numbered links to routers and virtual links, this field specifies the IP interface address of the associated router interface (this is needed by the routing table calculation, see Section 16.1.1). For links to stub networks, this field specifies the network's IP address mask. For unnumbered point-to-point networks, the Link Data field should be set to the unnumbered interface's MIB-II [RFC 1213] ifIndex value.

Finally, the cost of using the link for output (possibly specifying a different cost for each Type of Service) is specified. The output cost of a link is configurable. It must always be non-zero.

To further describe the process of building the list of link descriptions, suppose a router wishes to build a router links advertisement for Area A. The router examines its collection of interface data structures. For each interface, the following steps are taken:

Unless otherwise specified, the cost of each link generated by the above procedure is equal to the output cost of the associated interface. Note that in the case of serial lines, multiple links may be generated by a single interface.

After consideration of all the router interfaces, host links are added to the advertisement by examining the list of attached hosts. A host route is represented as a Type 3 link (stub network) whose Link ID is the host's IP address and whose Link Data is the mask of all ones (0xffffffff).

As an example, consider the router links advertisements generated by Router RT3, as pictured in Figure 6. The area containing Router RT3 (Area 1) has been redrawn, with actual network addresses, in Figure 15. Assume that the last byte of all of RT3's interface addresses is 3, giving it the interface addresses 192.1.1.3 and 192.1.4.3, and that the other routers have similar addressing schemes. In addition, assume that all links are functional, and that Router IDs are assigned as the smallest IP interface address.

RT3 originates two router links advertisements, one for Area 1 and one for the backbone. Assume that Router RT4 has been selected as the Designated router for network 192.1.1.0. RT3's router links advertisement for Area 1 is then shown below. It indicates that RT3 has two connections to Area 1, the first a link to the transit network 192.1.1.0 and the second a link to the stub network 192.1.4.0. Note that the transit network is identified by the IP interface of its Designated Router (i.e., the Link ID = 192.1.1.4 which is the Designated Router RT4's IP interface to 192.1.1.0). Note also that RT3 has indicated that it is capable of calculating separate routes based on IP TOS, through setting the T-bit in the Options field. It has also indicated that it is an area border router.

              ; RT3's router links advertisement for Area 1

              LS age = 0                     ;always true on origination
              Options = (T-bit|E-bit)        ;TOS-capable
              LS type = 1                    ;indicates router links
              Link State ID = 192.1.1.3      ;RT3's Router ID
              Advertising Router = 192.1.1.3 ;RT3's Router ID
              bit E = 0                      ;not an AS boundary router
              bit B = 1                      ;area border router
              #links = 2
                     Link ID = 192.1.1.4     ;IP address of Desig. Rtr.
                     Link Data = 192.1.1.3   ;RT3's IP interface to net
                     Type = 2                ;connects to transit network
                     # other metrics = 0
                     TOS 0 metric = 1

                     Link ID = 192.1.4.0     ;IP Network number
                     Link Data = 0xffffff00  ;Network mask
                     Type = 3                ;connects to stub network
                     # other metrics = 0
                     TOS 0 metric = 2

Next RT3's router links advertisement for the backbone is shown. It indicates that RT3 has a single attachment to the backbone. This attachment is via an unnumbered point-to- point link to Router RT6. RT3 has again indicated that it is TOS-capable, and that it is an area border router.

              ; RT3's router links advertisement for the backbone

              LS age = 0                     ;always true on origination
              Options = (T-bit|E-bit)        ;TOS-capable
              LS type = 1                    ;indicates router links
              Link State ID = 192.1.1.3      ;RT3's router ID
              Advertising Router = 192.1.1.3 ;RT3's router ID
              bit E = 0                      ;not an AS boundary router
              bit B = 1                      ;area border router
              #links = 1
                     Link ID = 18.10.0.6     ;Neighbor's Router ID
                     Link Data = 0.0.0.3     ;MIB-II ifIndex of P-P link
                     Type = 1                ;connects to router
                     # other metrics = 0
                     TOS 0 metric = 8

Even though Router RT3 has indicated that it is TOS-capable in the above examples, only a single metric (the TOS 0 metric) has been specified for each interface. Different metrics can be specified for each TOS. The encoding of TOS in OSPF link state advertisements is described in Section 12.3.

As an example, suppose the point-to-point link between Routers RT3 and RT6 in Figure 15 is a satellite link. The AS administrator may want to encourage the use of the line for high bandwidth traffic. This would be done by setting the metric artificially low for the appropriate TOS value. Router RT3 would then originate the following router links advertisement for the backbone (TOS 8 = maximize throughput):

              ; RT3's router links advertisement for the backbone

              LS age = 0                  ;always true on origination
              Options = (T-bit|E-bit)     ;TOS-capable
              LS type = 1                 ;indicates router links
              Link State ID = 192.1.1.3   ;RT3's Router ID
              Advertising Router = 192.1.1.3
              bit E = 0                   ;not an AS boundary router
              bit B = 1                   ;area border router
              #links = 1
                     Link ID = 18.10.0.6  ;Neighbor's Router ID
                     Link Data = 0.0.0.3  ;MIB-II ifIndex of P-P link
                     Type = 1             ;connects to router
                     # other metrics = 1
                     TOS 0 metric = 8
                             TOS = 8      ;maximize throughput
                             metric = 1   ;traffic preferred


Next: 12.4.2. Network links

Connected: An Internet Encyclopedia
12.4.1. Router links