As we know, configuring the BGP neighbor is not too difficult, but when we are going to configure 100 or more Number of neighbors, then it becomes pretty tedious activity.

So, to minimize this configuration overhead, we use concept of BGP peer Group, where we can group the BGP Neighbors who are sharing the same outbound polices. But first we need to manually configure 100 Peers and then add to the peer group. Hence the problem is still not resolved.

Let’s verify BGP peer Group configuration

1 Example: Configuration step of iBGP Peer Group.

2 Example: Configuration step of eBGP peer Group.

With the Dynamic BGP peering feature, BGP router dynamically establishes peering with group of remote neighbors that are configured using a range of IP addresses and BGP peer group.After a subnet range is configured for a BGP peer group and a TCP session is initiated by another router for an IP address in the subnet range, a new BGP neighbor is dynamically created as a member of that group.

So in this scenario, we will discuss on how to configure Dynamic BGP peer.

As per diagram R1 wants dynamic peering with R2 and R3, so let’s verify the configuration steps;

Step 1. Define BGP peer group name

R1(config-router)# neighbor  Dynamic-peer peer-group

Step 2. Create a global limit of BGP dynamic subnet range neighbors. The value ranges from 1 to 5000.

R1(config-router)# bgp listen limit 100

Step 3. Define the IP Subnet Range and associate it with a peer group. Multiple subnets can be added to the same peer group.

R1(config-router)# bgp listen range peer-group Dynamic-peer

Step 4. Define the remote-as for the peer group. Optionally, define the list of AS numbers that can be accepted to form neighborship with. The max limit of alternate-as numbers is 5.

R1(config-router)# neighbor Dynamic-peer  remote-as 65002 alternate-as 65003 65004

Step 5. Activate the peer group under ipv4 address-family

R1(config-router)#address-family ipv4

R1(config-router-af)# neighbor Dynamic-peer  activate.

Router1#show run | section router bgp

router bgp 65001

bgp log-neighbor-changes

bgp listen range peer-group Dynamic-peer

neighbor Dynamic-peer peer-group

neighbor Dynamic-peer remote-as 65002 alternate-as 65003 65004


address-family ipv4

neighbor Dynamic-peer activate


Router2#show run | section bgp

router bgp 65002

bgp log-neighbor-changes

neighbor remote-as 65001

Router3#show run | section router bgp

router bgp 65003

bgp log-neighbor-changes

neighbor remote-as 65001

Router1#show ip bgp summary

BGP router identifier, local AS number 65001

BGP table version is 1, main routing table version 1


Neighbor        V           AS    MsgRcvd    MsgSent   TblVer     InQ OutQ    Up/Down    State/PfxRcd

*     4        65002       4                 4             1              0    0         00:00:38        0

*     4        65003       4                 2             1              0    0         00:00:29        0

* Dynamically created based on a listen range command

Dynamically created neighbors: 2, Subnet ranges: 1

BGP peergroup Dynamic-peer listen range group members:

Total dynamically created neighbors: 2/(100 max), Subnet ranges: 1

Router1#show tcp brief all

TCB                    Local Address                 Foreign Address                     (state)

A2B61B90                        ESTAB

A2B62F48                        ESTAB

A2B19B20                            *.*                                       LISTEN

The output illustrates that the router is listening on port 179 but with foreign address of *.*

Please follow and like us:

Add Comment

Social Media Auto Publish Powered By : XYZScripts.com
Select your currency
USD United States (US) dollar

Checkout : E-STORE for latest release "Networking Scenario Based Interview Q&A " Dismiss