Reference Guide

Border Gateway Protocol | 179
In BGP, neighbor routers or peers can be classified as internal or external. External BGP peers must be
connected physically to one another (unless you enable the EBGP multihop feature), while internal BGP
peers do not need to be directly connected. The IP address of an EBGP neighbor is usually the IP address
of the interface directly connected to the router. First, the BGP process determines if all internal BGP peers
are reachable, and then it determines which peers outside the AS are reachable.
Use these commands in the following sequence, starting in the CONFIGURATION mode to establish BGP
sessions on the router.
Note: Sample Configurations for enabling BGP routers are found at the end of this chapter.
Step Command Syntax Command Mode Purpose
1 router bgp as-number CONFIGURATION Assign an AS number and enter the
ROUTER BGP mode.
AS Number: 0-65535 (2-Byte) or
1-4294967295 (4-Byte) or 0.1-65535.65535
(Dotted format)
Only one AS is supported per system
If you enter a 4-Byte AS Number, 4-Byte AS Support is enabled
automatically.
1a bgp four-octet-as-support CONFIG-ROUTER-BGP Enable 4-Byte support for the BGP process.
Note: This is an OPTIONAL command.
Enable if you want to use 4-Byte AS
numbers or if you support AS4 Number
Representation.
Use it only if you support 4-Byte AS Numbers or if you support AS4
Number Representation. If you are supporting 4-Byte ASNs, this
command must be enabled first.
Disable 4-Byte support and return to the default 2-Byte format by using
the no bgp four-octet-as-support command. You cannot disable
4-Byte support if you currently have a 4-Byte ASN configured.
Disabling 4-Byte AS Numbers also disables ASDOT and ASDOT+
number representation. All AS Numbers will be displayed in ASPLAIN
format.
1b address-family [ipv4 | ipv6} CONFIG-ROUTER-BGP Enable IPv4 multicast or IPv6 mode.
Use this command to enter BGP for IPv6
mode (CONF-ROUTER_BGPv6_AF).
2
neighbor {ip-address |
peer-group name} remote-as
as-number
CONFIG-ROUTER-BGP Add a neighbor as a remote AS.
Formats:
IP Address A.B.C.D
Peer-Group Name: 16 characters
AS-number: 0-65535 (2-Byte) or
1-4294967295 (4-Byte) or 0.1-65535.65535
(Dotted format)