Skip to content

Commit

Permalink
Update openconfig-network-instance.yang (#987)
Browse files Browse the repository at this point in the history
* Clarify network_instance_redistribution and default route policy

---------

Co-authored-by: Darren Loher <[email protected]>
Co-authored-by: Wen Bo Li <[email protected]>
  • Loading branch information
3 people authored Nov 16, 2023
1 parent 28a7b6b commit adf582e
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 3 deletions.
5 changes: 4 additions & 1 deletion doc/network_instance_redistribution.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ In numerous use cases an operator wishes to take routes that exist in one protoc

In those implementations that maintain a (virtual-) RIB per protocol, the operator must configure explicit connections between these tables, usually alongside a policy to allow such inter-protocol advertisement to occur. While no such configuration is required in those implementations that utilise a single RIB, it is notable that even in these implementations a protocol will not advertise another protocol's routes from the RIB by default (since such a setup would mean that for instance, the BGP DFZ would be re-advertised into the IGP at peering edge devices, which is clearly not desirable). Instead, an operator must create explicit configuration that matches routes installed into the RIB by a particular protocol, and then "import" these routes into the protocol that is expected to advertise them.

In this latter case, the use of an import policy within a particular protocol instance is equivalent to the former - with the only difference being the context in which the policy is defined. With a table per protocol, an explicit configuration of redistributing routes from protocol A to protocol B is specified. In the latter case, the target protocol (protocol B) is specified, and a policy is used to select the source protocols from which routes may be imported for advertisement.
In this latter case, the use of an import policy within a particular protocol instance is equivalent to the former - with the only difference being the context in which the policy is defined. With a table per protocol, an explicit configuration of redistributing routes from protocol A to protocol B is specified. In the latter case, the target protocol (protocol B) is specified, and a policy is used to select the source protocols from which routes may be imported for advertisement.
In both cases, the destination protocol (protocol B) only installs the redistributed routes from the source protocol (protocol A) in its "advertisement RIB view". The redistributed routes are not installed in the FIB (forwarding information base) and therefore are not used for forwarding.

## OpenConfig Approach to Protocol RIB Interconnection

Expand All @@ -35,6 +36,8 @@ An OpenConfig `routing-policy` is specified along with the connection - allowing

It is expected that protocol-specific attributes (e.g., BGP communities) are set by such an import policy, allowing routes that are redistributed to carry information relating to their source (e.g., an IGP route may be tagged with a specific community using policy to indicate its provenance).

In the absense of an import-policy for table-connections, default-import-policy should take effect. In the absence of both, no routes should be allowed to be redistributed.

## Examples of OpenConfig Network instance

### Example: Aggregate Routes Redistributed to IS-IS Level 2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,13 @@ submodule openconfig-network-instance-l2 {
Layer 2 network instance configuration and operational state
parameters.";

oc-ext:openconfig-version "4.2.1";
oc-ext:openconfig-version "4.2.2";

revision "2023-11-03" {
description
"Add reference URL for Route Redistribution rules";
reference "4.2.2";
}

revision "2023-11-01" {
description
Expand Down
12 changes: 11 additions & 1 deletion release/models/network-instance/openconfig-network-instance.yang
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,13 @@ module openconfig-network-instance {
virtual switch instance (VSI). Mixed Layer 2 and Layer 3
instances are also supported.";

oc-ext:openconfig-version "4.2.1";
oc-ext:openconfig-version "4.2.2";

revision "2023-11-03" {
description
"Add reference URL for Route Redistribution rules";
reference "4.2.2";
}

revision "2023-11-01" {
description
Expand Down Expand Up @@ -487,6 +493,10 @@ module openconfig-network-instance {
for the connection are available for the destination
protocol to advertise, or match within its policies.";

reference
"Route Redistribution in OpenConfig Network Instance:
https://github.com/openconfig/public/blob/master/doc/network_instance_redistribution.md#interconnection-of-protocol-ribs";

leaf src-protocol {
type leafref {
path "../config/src-protocol";
Expand Down

0 comments on commit adf582e

Please sign in to comment.