跳到主要内容

3.2. Routing Information Base

3.2. Routing Information Base

BGP speaker 内部的 Routing Information Base (RIB) 由三个不同部分组成:

a) Adj-RIBs-In: Adj-RIBs-In 存储从其他 BGP speaker 接收的 incoming UPDATE message 中学到的 routing information. 其内容表示可作为 Decision Process 输入的 route.

b) Loc-RIB: Loc-RIB 包含 BGP speaker 通过将其 local policy 应用于 Adj-RIBs-In 中包含的 routing information 而选择的 local routing information. 这些是 local BGP speaker 使用的 route. 每条此类 route 的 Next-Hop MUST 可通过 local BGP speaker 的 Routing Table 解析.

c) Adj-RIBs-Out: Adj-RIBs-Out 存储 local BGP speaker 已选择用于向其 peer 通告的信息. 存储在 Adj-RIBs-Out 中的 routing information 在 local BGP speaker 的 UPDATE message 中携带, 并通告给其 peer.

概括而言: Adj-RIBs-In 包含由 peer 向 local BGP speaker 通告的未处理 routing information; Loc-RIB 包含由 local BGP speaker 的 Decision Process 选择的 route; Adj-RIBs-Out 组织将通告给特定 peer 的 route (通过 local speaker 的 UPDATE message).

虽然概念模型区分 Adj-RIBs-In, Loc-RIB 和 Adj-RIBs-Out, 但这既不暗示也不要求 implementation 必须保留三份独立 routing information 副本. implementation 的选择 (例如 3 份信息副本 vs. 1 份带指针的副本) 不受 protocol 限制.

BGP speaker 用于转发 packet (或构造用于 packet forwarding 的 forwarding table) 的 routing information 在 Routing Table 中维护. Routing Table 累积到 directly connected network 的 route, static route, 从 IGP protocol 学到的 route, 以及从 BGP 学到的 route. 某条特定 BGP route 是否应安装到 Routing Table 中, 以及某条 BGP route 是否应覆盖另一来源安装的到同一 destination 的 route, 是 local policy decision, 本文档不作规定. 除实际 packet forwarding 之外, Routing Table 还用于解析 BGP update 中指定的 Next-Hop address (见 Section 5.1.3).