neighbor remote-as

Syntax

neighbor {<IP-ADDR>|<PEER-GROUP-NAME>} remote-as <AS-NUMBER>

no neighbor {<IP-ADDR>|<PEER-GROUP-NAME>} remote-as <AS-NUMBER>

Description

Creates a peer, initiates the connection to the peer, and adds an entry to the BGP neighbor table. Specifies a neighbor with an autonomous system (AS) number that identifies the neighbor as internal to the local autonomous system. Otherwise, the neighbor is considered as external. By default, neighbors that are defined using this command, exchange only unicast address prefixes.

The no form of this command disables the peer session and deletes the peer information.

Command context

config-bgp

Parameters

<IP-ADDR>

Specifies an IP address.

<PEER-GROUP-NAME>

Specifies a peer group.

remote-as <AS-NUMBER>

Specifies a 4-byte AS number in asplain format (z), or asdot format (x.y), where z is a number from 1 to 4294967295 and x and y are 16-bit numbers in the range 0 to 65535.

Authority

Administrators or local user group members with execution rights for this command.

Usage

The configured peer AS number is compared with the AS number received in the open message and a peer session is initiated only if both the AS numbers match.

Examples

switch(config-bgp)# neighbor 1.1.1.1 remote-as 1
switch(config-bgp)# no neighbor 1.1.1.1 remote-as 1
switch(config-bgp)# neighbor pg remote-as 1
switch(config-bgp)# no neighbor pg remote-as 1