route-distinguisher (VPN instance IPv4 address family view)

Function

The route-distinguisher command configures an RD for a VPN instance IPv4 address family.

The undo route-distinguisher command deletes the RD configuration in a specified VPN instance IPv4 address family.

By default, no RD is configured for a VPN instance IPv4 address family.

Format

route-distinguisher route-distinguisher

undo route-distinguisher route-distinguisher

Parameters

Parameter Description Value
route-distinguisher

Specifies a VPN target to be configured for a VPN instance IPv4 address family.

The format of a VPN target can be as follows:

  • 2-byte AS number: 4-byte user-defined number, for example, 1:3. An AS number is an integer ranging from 0 to 65535, and a user-defined number is an integer ranging from 0 to 4294967295. The AS and user-defined numbers cannot be both 0s. This means that a VPN target cannot be 0:0.
  • Integral 4-byte AS number: 2-byte user-defined number, for example, 65537:3. An AS number is an integer ranging from 65536 to 4294967295, and a user-defined number is an integer ranging from 0 to 65535.
  • 4-byte AS number in dotted notation: 2-byte user-defined number, for example, 0.0:3 or 0.1:0. A 4-byte AS number in dotted notation is in the format of x.y, where x and y are integers ranging from 0 to 65535. A user-defined number is an integer ranging from 0 to 65535. The AS and user-defined numbers cannot be both 0s. This means that a VPN target cannot be 0.0:0.
  • 32-bit IP address: 2-byte user-defined number. For example, 192.168.122.15:1. An IP address ranges from 0.0.0.0 to 255.255.255.255, and a user-defined number is an integer ranging from 0 to 65535.

Views

VPN instance IPv4 address family view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
l3vpn write

Usage Guidelines

Usage Scenario

After creating a VPN instance and enabling the IPv4 address family for the VPN instance, you must run the route-distinguisher command to configure an RD for the address family.

Different VPN instances may have the same route prefix. To allow a PE to determine to which VPN instance a route belongs, run the route-distinguisher command to configure an RD for the VPN instance IPv4 address family on the PE. After the configuration, the PE will add an RD to the route received from the VPN instance, and then the route prefix becomes a globally unique VPN IPv4 route.

Precautions

After an RD in the IPv4 address family for a VPN instance is deleted using the undo route-distinguisher command, configurations in the IPv4 address family as well as the IPv4 address family-related configurations in the BGP view will be deleted. Therefore, exercise caution when you run this command.

Example

# Configure an RD for the VPN instance named vpn1.
<HUAWEI> system-view
[~HUAWEI] ip vpn-instance vpn1
[*HUAWEI-vpn-instance-vpn1] ipv4-family
[*HUAWEI-vpn-instance-vpn1-af-ipv4] route-distinguisher 22:1
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >