4.1. Type-7 LSA から Type-5 LSA への変換
このステップは、type-5 および type-7 のルートが計算された後、NSSA のダイクストラ計算の一部として実行される。計算を行うルータがエリア境界ルータでない場合、この変換アルゴリズムはスキップすべきである。NSSA 内の到達可能なすべてのエリア境界ルータを調べ、ルータ ID が最大のものを確認する。このルータが最大のルータ ID を持つ場合、このルータが NSSA に対して type-7 LSA を type-5 LSA に変換するルータとなり、そうでなければ変換アルゴリズムを実行すべきではない。ルーティングテーブルに追加されたすべての type-7 ルートを調べる。検討中のルートに関連する type-7 LSA に P ビットが設定され、かつ非ゼロの転送アドレスがある場合は、次の手順を実行すべきである。
The translation procedure must first check for a configured type-7
address range. Recall that an type-7 address range consists of an
[address,mask] pair and a status indication of either Advertise or
DoNotAdvertise. At most a single type-5 LSA is made for each
range. If the route being examined falls within the type-7
address range, (the [address,mask] pair of the route equal to or a
more specific instance of the [address,mask] pair of the type-7
address range), one of following three actions may take place.
1. When the range's status indicates Advertise and the
route's address and mask are equal to the address
and mask of the type-7 range a type-5 LSA should be
originated if:
o there currently is no type-5 LSA originated from
this router corresponding to the type-7 LSA,
o the path type or the metric in the corresponding
type-5 LSA is different from the type-7 LSA or
o The forwarding address in the corresponding
type-5 LSA is different from the type-7 LSA.
The newly originated type-5 LSA will describe
the same network and have the same network mask,
metrics, forwarding address, external route tag
and path type as the type-7 LSA, however, the
advertising router field will be the router ID
of this area border router.
2. When the range's status indicates Advertise and the
route's address or mask indicates a more specific
route (i.e., the route's address is subsumed by the
range or the route has a longer mask), a type-5 LSA
is generated with link-state ID equal to the range's
address (if necessary, the link-state ID can also have
one or more of the range's "host" bits set; see
Appendix F of the OSPF specification for details),
the network mask, external route tag and
path type will be set to the configured type-7 range
values. The advertising router field will be the
router ID of this area border router.
The forwarding address will not be set.
The path type should always be set to the highest
path type that is subsumed by the net range.
The metric for the type-5 LSA will be set as follows:
o if the path type is externl type 2, the type-5
metric should be set to the largest type-7 metric
subsumed by this net range + 1.
o if the path type is external type 1, the type-5
metric should be set to the largest metric.
For example, given a net range of [10.0.0.0, 255.0.0.0]
for an area that has type-7 routes of:
10.1.0.0 path type 1, metric 10
10.2.0.0 path type 1, metric 11
10.3.0.0 path type 2, metric 5
a type-5 LSA will be generated with a path type of 2
and a metric of 6.
As another example, given a net range of
[10.0.0.0, 255.0.0.0] for an area that has
type-7 routes of:
10.1.0.0 path type 1, metric 10
10.2.0.0 path type 1, metric 11
10.3.0.0 path type 1, metric 5
a type-5 LSA will be generated with a path type of 1
and a metric of 11.
These metric and path type rules will avoid routing
loops in the event that path type 1 and 2 are both
used within the area.
3. When the range's status indicates DoNotAdvertise,
the type-5 LSA is suppressed and the component networks
remain hidden from the rest of the AS.
By default (given that the P-bit is set and the LSA has a
non-zero forwarding address) if a network is not contained
in any explicitly configured address range, a type-7 to
type-5 LSA translation will occur.
A new instance of a type-5 LSA should be originated and
flooded to all attached type-5 capable areas if one of the
following is true.
1. There currently is no type-5 LSA originated from this
router corresponding to the type-7 LSA.
2. The path type or the metric in the corresponding
type-5 LSA is different from the type-7 LSA.
3. The forwarding address in the corresponding
type-5 LSA is different from the type-7 LSA.
The newly originated type-5 LSAs will describe the same
network and have the same network mask, metrics, forwarding
address, external route tag and path type as the type-7 LSA.
The advertising router field will be the router ID of this
area border router.
As with all newly originated type-5 LSAs, a type-5 LSA that
is the result of a type-7 to type-5 translation (type-7 range
or default case) is flooded to all attached type-5 capable
areas.