if-match rd-filter

Function

The if-match rd-filter command sets a matching rule that is based on the Route Distinguisher (RD) filter.

The undo if-match rd-filter command cancels the configuration.

By default, no route filtering based on the RD is configured.

Format

if-match rd-filter rd-filter-number

undo if-match rd-filter

Parameters

Parameter Description Value
rd-filter-number Specifies the number of the RD filter. The value is an integer ranging from 1 to 255.

Views

Route-policy view or tunnel selector view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

The if-match rd-filter command must be used with the ip rd-filter command so that the matching rule configured through the if-match rd-filter command to filter routes received from neighbors based on the RD filter can take effect. For example:

  • If the if-match rd-filter 1 command is used but rd-filter 1 is not configured, all routes are permitted.

  • If the if-match rd-filter 1 command is used after the ip rd-filter 1 permit 1:1 command is used, the routes with the RD being 1:1 are permitted.

Prerequisites

The if-match rd-filter command can be used only after the route-policy command or the tunnel-selector is used.

Configuration Impact

When you filter routes based on the RDs, the routes that match the matching rule are permitted and the routes that do not match the matching rule are denied.

Example

# Define a rule to match the RD filter.

<sysname> system-view
[sysname] route-policy abc permit node 10
[sysname-route-policy] if-match rd-filter 1
# Define a rule to filter routes based on the RD in the tunnel selector view.
<sysname> system-view
[sysname] tunnel-selector tps permit node 10
[sysname-tunnel-selector] if-match rd-filter 1
Related Topics
ip rd-filter
display ip rd-filter

Huawei Proprietary and Confidential
Copyright © Huawei Technologies Co., Ltd.