MVPN VRF Import and Export Policies
Configuring VRF Route Targets for Routing Instances for an MBGP MVPN
By default, the VPN routing and forwarding (VRF) import and
export route targets (configured either using VRF import and export
policies or using the vrf-target
statement) are used for
importing and exporting routes with the MBGP MVPN network layer reachability
information (NLRI).
You can use the export-target
and import-target
statements to override the default VRF import and export route targets.
Export and import targets can also be specified specifically for sender
sites or receiver sites, or can be borrowed from a configured unicast
route target. Note that a sender site export route target is always
advertised when security association routes are exported.
When you configure an MBGP MVPN routing instance, you should not configure a target value for an MBGP MVPN specific route target that is identical to a target value for a unicast route target configured in another routing instance.
Specifying route targets in the MBGP MVPN NLRI for sender and receiver sites is useful when there is a mix of sender only, receiver only, and sender and receiver sites. A sender site route target is used for exporting automatic discovery routes by a sender site and for importing automatic discovery routes by a receiver site. A receiver site route target is used for exporting routes by a receiver site and importing routes by a sender site. A sender and receiver site exports and imports routes with both route targets.
A provider edge (PE) router with sites in a specific MBGP MVPN must determine whether a received automatic discovery route is from a sender site or receiver site based on the following:
If the PE router is configured to be only in a sender site, route targets are imported only from receiver sites. Imported automatic discovery routes must be from a receiver site.
If the PE router is configured to be only in a receiver site, route targets are imported only from sender sites. Imported automatic discovery routes must be from a sender site.
If a PE router is configured to be in both sender sites and receiver sites, these guidelines apply:
Along with an import route target, you can optionally configure whether the route target is from a receiver or a sender site.
If a configuration is not provided, an imported automatic discovery route is treated as belonging to both the sender site set and the receiver site set.
To configure a route target for the MBGP MVPN routing instance,
include the route-target
statement:
route-target { export-target { target target-community; unicast; } import-target { target { target-value; receiver target-value; sender target-value; } unicast { receiver; sender; }
You can include this statement at the following hierarchy levels:
[edit routing-instances routing-instance-name protocols mvpn]
[edit logical-systems logical-system-name routing-instances routing-instance-name protocols mvpn]
The following sections describes how to configure the export target and the import target for an MBGP MVPN:
Configuring the Export Target for an MBGP MVPN
To configure an export target, include the export-target
statement:
export-target { target target-community; unicast; }
You can include this statement at the following hierarchy levels:
[edit routing-instances routing-instance-name protocols mvpn route-target]
[edit logical-systems logical-system-name routing-instances routing-instance-name protocols mvpn route target]
Configure the target
option to specify the export
target community. Configure the unicast
option to use the
same target community that has been specified for unicast.
Configuring the Import Target for an MBGP MVPN
To configure an import target, include the import-target
statement:
import-target { target target-value { receiver; sender; } unicast { receiver; sender; } }
You can include this statement at the following hierarchy levels:
[edit routing-instances routing-instance-name protocols mvpn route-target]
[edit logical-systems logical-system-name routing-instances routing-instance-name protocols mvpn route-target]
The following sections describe how to configure the import target and unicast parameters:
- Configuring the Import Target Receiver and Sender for an MBGP MVPN
- Configuring the Import Target Unicast Parameters for an MBGP MVPN
Configuring the Import Target Receiver and Sender for an MBGP MVPN
To configure the import target community, include the target
statement and specify the target community. The target community
must by in the format target:x:y
. The x
value
is either an IP address or an AS number followed by an optional L
to indicate a 4 byte AS number, and y
is a number
(for example, target:123456L:100
)
target target-value { receiver; sender; }
You can include this statement at the following hierarchy levels:
[edit routing-instances routing-instance-name protocols mvpn route-target import-target]
[edit logical-systems logical-system-name routing-instances routing-instance-name protocols mvpn route-target import-target]
You can specify the target community used when importing either receiver site sets or sender site sets by including one of the following statements:
receiver
—Specify the target community used when importing receiver site sets.sender
—Specify the target community used when importing sender site sets.
Configuring the Import Target Unicast Parameters for an MBGP MVPN
To configure a unicast target community as the import target,
include the unicast
statement:
unicast { receiver; sender; }
You can include this statement at the following hierarchy levels:
[edit routing-instances routing-instance-name protocols mvpn route-target import-target]
[edit logical-systems logical-system-name routing-instances routing-instance-name protocols mvpn route-target import-target]
You can specify the unicast target community used when importing either receiver site sets or sender site sets by including one of the following statements:
receiver
—Specify the unicast target community used when importing receiver site sets.sender
—Specify the unicast target community used when importing sender site sets.
Limiting Routes to Be Advertised by an MVPN VRF Instance
If a hub-and-spoke deployment uses one VPN routing and forwarding (VRF) routing instance for unicast routing and a separate VRF for MVPN routing, you need to limit the PE routers at the hub site to advertise only IPv4 MVPN routes, only IPv6 MVPN routes, or both. This is necessary to prevent the multicast VRF instance from advertising unicast VPN routes to other PE routers.
This configuration does not prevent the exportation of
VPN routes to other VRF instances on the same router if the auto-export
statement is included in the [edit routing-options]
hierarchy.
To configure a VRF routing instance with the name green
to advertise MVPN routes from both the inet
and inet6
address families, perform the following steps:
After the configuration is committed, only the MVPN routes for
the specified address families are advertised from the VRF instance
to remote PE routers. To remove the restriction on routes being advertised,
delete the vrf-advertise-selective
statement.
You cannot include the vrf-advertise-selective
statement and the no-vrf-advertise
statement in the same
VRF configuration. However, if you configure the vrf-advertise-selective
statement without any of its options, the router has the same behavior
as if you configured the no-vrf-advertise
statement. VPN
routes are prevented from being advertised from a VRF routing instance
to the remote PE routers.