peer (BGP-VPN instance IPv4 address family view) (group)

Function

The peer listen-only command configures a peer group to only listen to connection requests and not to initiatively send connection requests.

The undo peer listen-only command cancels the function.

The peer connect-only command configures a peer group to send connection requests but rejects connection requests.

The undo peer connect-only command restores the default setting.

By default, a peer group listens to, accepts, and proactively sends connection requests.

Format

peer group-name { listen-only | connect-only }

undo peer group-name { listen-only | connect-only }

Parameters

Parameter Description Value
group-name

Specifies the name of a peer group.

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

Views

BGP-VPN instance IPv4 address family view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
bgp write

Usage Guidelines

Usage Scenario

The peer listen-only command is used to configure a peer group to only listen to connection requests and not to initiatively send connection requests.

The peer connect-only command is used to configure a peer group to send connection requests but rejects connection requests.

Configuration Impact

If the peer listen-only command is run multiple times, the latest configuration overwrites the previous one.

After being configured with the peer listen-only command, a peer does not initiate any connection request.

Precautions

The peer listen-only command can be run at only one end of a peer relationship. If this command is run at both ends of a peer relationship, the ends fail to establish a connection.

The peer connect-only command or the peer listen-only command cannot be run on two devices that will establish a peer relationship. Otherwise, no peer relationship can be established between the two devices.

Example

# Enable peer group to send connection requests but rejects connection requests.
<HUAWEI> system-view
[~HUAWEI] ip vpn-instance vpn1
[*HUAWEI-vpn-instance-vpn1] ipv4-family
[*HUAWEI-vpn-instance-vpn1-af-ipv4] route-distinguisher 100:1
[*HUAWEI-vpn-instance-vpn1-af-ipv4] quit
[*HUAWEI-vpn-instance-vpn1] quit
[*HUAWEI] bgp 100
[*HUAWEI-bgp] ipv4-family vpn-instance vpn1
[*HUAWEI-bgp-vpn1] group test
[*HUAWEI-bgp-vpn1] peer test connect-only
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >