Configure BGP4 Dynamic Neighbors

The peer group is added to the BGP neighbor table of the local device and an alternate ASN is configured.
  1. Access global configuration mode.
    device# configure terminal
  2. Access BGP configuration mode.
    device(config)# router bgp
  3. Specify the autonomous system in which your device resides.
    device(config-bgp-router)# local-as 100
  4. Create a peer group.
    device(config-bgp-router)# neighbor leaf-group peer-group
    This example creates a peer group called leaf-group.
  5. Specify an autonomous system for the peer group.
    device(config-bgp-router)# neighbor leaf-group remote-as 100
  6. Associate a subnet range with the BGP peer group.
    device(config-bgp-router)# listen-range 2000:1:1::/48 peer-group leaf-group 
    This example specifies the 2000:1:1::/48 subnet range.
  7. Specify an alternate autonomous system for listen range neighbors in the configured peer group.
    device(config-bgp-router)# neighbor mypeergroup1 alternate-as add 200,300

Example

The following example summarizes the commands in this procedure.

device# configure terminal
device(config)# router bgp
device(config-bgp-router)# local-as 65520
device(config-bgp-router)# neighbor mypeergroup1 peer-group
device(config-bgp-router)# neighbor mypeergroup1 remote-as 80
device(config-bgp-router)# listen-range 150.1.0.0/16 peer-group mypeergroup1 limit 20
device(config-bgp-router)# neighbor mypeergroup1 alternate-as add 101