The Loc-RIB contains all routes selected by the BGP Decision Process as described in
Section 9.1 of
RFC 4271. These routes include those learned from BGP peers via its Adj-RIBs-In post-policy, as well as routes learned by other means as per
Section 9.4 of
RFC 4271. Examples of these include redistribution of routes from other protocols into BGP or those otherwise locally originated (i.e., aggregate routes).
As described in
Section 6.1.2, a subset of Loc-RIB routes
MAY be sent to a BMP collector by setting the F flag.
All peer messages that include a per-peer header as defined in
Section 4.2 of
RFC 7854 MUST use the following values:
-
Peer Type:
-
Set to 3 to indicate Loc-RIB Instance Peer.
-
Peer Distinguisher:
-
Zero-filled if the Loc-RIB represents the global instance. Otherwise, set to the route distinguisher or unique locally defined value of the particular instance to which the Loc-RIB belongs.
-
Peer Address:
-
Zero-filled. The remote peer address is not applicable. The V flag is not applicable with the Loc-RIB Instance Peer Type considering addresses are zero-filled.
-
Peer Autonomous System (AS):
-
Set to the primary router BGP autonomous system number (ASN).
-
Peer BGP ID:
-
Set the ID to the router-id of the VRF instance if VRF is used; otherwise, set to the global instance router-id.
-
Timestamp:
-
The time when the encapsulated routes were installed in the Loc-RIB, expressed in seconds and microseconds since midnight (zero hour), January 1, 1970 (UTC). If zero, the time is unavailable. Precision of the timestamp is implementation dependent.
Peer Up notifications follow
Section 4.10 of
RFC 7854 with the following clarifications:
-
Local Address:
-
Zero-filled; the local address is not applicable.
-
Local Port:
-
Set to 0; the local port is not applicable.
-
Remote Port:
-
Set to 0; the remote port is not applicable.
-
Sent OPEN Message:
-
This is a fabricated BGP OPEN message. Capabilities MUST include the 4-octet ASN and all necessary capabilities to represent the Loc-RIB Route Monitoring messages. Only include capabilities if they will be used for Loc-RIB monitoring messages. For example, if ADD-PATH is enabled for IPv6 and Loc-RIB contains additional paths, the ADD-PATH capability should be included for IPv6. In the case of ADD-PATH, the capability intent of advertise, receive, or both can be ignored since the presence of the capability indicates enough that additional paths will be used for IPv6.
-
Received OPEN Message:
-
Repeat of the same sent OPEN message. The duplication allows the BMP receiver to parse the expected received OPEN message as defined in Section 4.10 of RFC 7854.
The following Peer Up Information TLV type is added:
-
Type = 3: VRF/Table Name. The Information field contains a UTF-8 string whose value MUST be equal to the value of the VRF or table name (e.g., RD instance name) being conveyed. The string size MUST be within the range of 1 to 255 bytes.
The VRF/Table Name TLV is optionally included to support implementations that may not have defined a name. If a name is configured, it MUST be included. The default value of "global" MUST be used for the default Loc-RIB instance with a zero-filled distinguisher. If the TLV is included, then it MUST also be included in the Peer Down notification.
The Information field contains a UTF-8 string whose value
MUST be equal to the value of the VRF or table name (e.g., RD instance name) being conveyed. The string size
MUST be within the range of 1 to 255 bytes.
The VRF/Table Name TLV is optionally included to support implementations that may not have defined a name. If a name is configured, it
MUST be included. The default value of "global"
MUST be used for the default Loc-RIB instance with a zero-filled distinguisher. If the TLV is included, then it
MUST also be included in the Peer Down notification.
Multiple TLVs of the same type can be repeated as part of the same message, for example, to convey a filtered view of a VRF. A BMP receiver should append multiple TLVs of the same type to a set in order to support alternate or additional names for the same peer. If multiple strings are included, their ordering
MUST be preserved when they are reported.
The Peer Down notification
MUST use reason code 6. Following the reason is data in TLV format. The following Peer Down Information TLV type is defined:
-
Type = 3: VRF/Table Name. The Information field contains a UTF-8 string whose value MUST be equal to the value of the VRF or table name (e.g., RD instance name) being conveyed. The string size MUST be within the range of 1 to 255 bytes. The VRF/Table Name informational TLV MUST be included if it was in the Peer Up.
Route Monitoring messages are used for initial synchronization of the Loc-RIB. They are also used to convey incremental Loc-RIB changes.
As described in
Section 4.6 of
RFC 7854, "Following the common BMP header and per-peer header is a BGP Update PDU."
Loc-RIB Route Monitoring messages
MUST use a 4-byte ASN encoding as indicated in the
Section 5.2 capability.
State compression and throttling
SHOULD be used by a BMP sender to reduce the amount of Route Monitoring messages that are transmitted to BMP receivers. With state compression, only the final resultant updates are sent.
For example, prefix 192.0.2.0/24 is updated in the Loc-RIB 5 times within 1 second. State compression of BMP Route Monitoring messages results in only the final change being transmitted. The other 4 changes are suppressed because they fall within the compression interval. If no compression was being used, all 5 updates would have been transmitted.
A BMP receiver should expect that the granularity of Loc-RIB Route Monitoring can vary depending on the BMP sender implementation.
Section 4.7 of
RFC 7854 defines Route Mirroring for verbatim duplication of messages received. This is not applicable to Loc-RIB as PDUs are originated by the router. Any received Route Mirroring messages
SHOULD be ignored.
Not all Stat Types are relevant to Loc-RIB. The Stat Types that are relevant are listed below:
-
Stat Type = 8: (64-bit Gauge) Number of routes in Loc-RIB.
-
Stat Type = 10: Number of routes in per-AFI/SAFI Loc-RIB. The value is structured as: 2-byte AFI, 1-byte SAFI, followed by a 64-bit Gauge.