peer ip-prefix import (BGP-VPNv4 address family view) (IPv6)

Function

The peer ip-prefix import command configures a policy based on an IP prefix list for filtering BGP routes received from a specified peer.

The undo peer ip-prefix import command cancels this configuration.

By default, no route filtering policy based on an IP address prefix list is configured for a peer.

Format

peer ipv6-address ip-prefix ip-prefix-name import

undo peer ipv6-address ip-prefix [ ip-prefix-name ] import

Parameters

Parameter Description Value
ipv6-address

Specifies the IPv6 address of a peer.

The prefix is in the format of X:X:X:X:X:X:X:X.

ip-prefix ip-prefix-name

specifies the name of an IP address prefix list.

The name is a string of 1 to 169 case-sensitive characters, with spaces not supported. When double quotation marks are used around the string, spaces are allowed in the string.

import

Applies a filtering policy to the routes received from a peer.

-

Views

BGP-VPNv4 address family view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
bgp write

Usage Guidelines

Usage Scenario

The peer ip-prefix import command can be used to configure a route filtering policy that is based on an IP prefix list for filtering BGP routes to be received from a specified peer, implementing route control.

Prerequisites

If the peer ip-prefix command specifies an IP prefix list that does not exist for a peer, use the ip ip-prefix command to create an IP prefix list.

Configuration Impact

If an IP prefix list is specified for a peer group, all the members of the peer group inherit the configuration.

After an IP prefix list is specified for a peer, the peer filter the routes received from other peers based on the IP prefix list. Only the routes that pass the filtering of the IP prefix list can be received.

Precautions

If both this command and the peer route-filter import command are run, the latest configuration overrides the previous one.

If the length of the filter name is less than or equal to six characters and the name matches the first six characters of export or import, When you run the undo command, the filter name cannot be entered. You only need to enter the keyword import or export.

Example

# Configure a route filtering policy based on an IPv6 prefix list.
<HUAWEI> system-view
[~HUAWEI] ip ip-prefix list1 permit 0.0.0.0 32 greater-equal 32 less-equal 32
[*HUAWEI] bgp 100
[*HUAWEI-bgp] peer 2001:DB8:1::1 as-number 100
[*HUAWEI-bgp] ipv4-family vpnv4
[*HUAWEI-bgp-af-vpnv4] peer 2001:DB8:1::1 enable
[*HUAWEI-bgp-af-vpnv4] peer 2001:DB8:1::1 ip-prefix list1 import
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >