OS10 Enterprise Edition User Guide Release 10.4.0E(R3)

PDF

Peer templates

To configure multiple BGP neighbors at one time, you can create and populate a BGP peer template. An advantage of configuring peer templates is that members of a peer template inherit the configuration properties of the template and share update policy. Always create a peer template and assign a name to it before adding members to the peer template. Create a peer template before configuring any route policies for the template.

  • NOTE: An outbound filter policy, distribute list or route map, is not supported on a peer group member.
  1. Enable BGP, and assign the AS number to the local BGP speaker in CONFIGURATION mode, from 1 to 65535 for 2 byte, 1 to 4294967295 | 0.1 to 65535.65535 for 4 byte, or 0.1 to 65535.65535 in dotted format.
    router bgp 
                                           as-number
                                        
  2. Create a peer template by assigning a neighborhood name to it in ROUTER-BGP mode.
    template 
                                           template-name
                                        
  3. Add a neighbor as a remote AS in ROUTER-BGP mode, from 1 to 65535 for 2 byte, 1 to 4294967295 | 0.1 to 65535.65535 for 4 byte, or 0.1 to 65535.65535 in dotted format.
    neighbor 
                                           ip-address
                                        
  4. Add a remote neighbor, and enter the AS number in ROUTER-NEIGHBOR mode.
    remote-as 
                                           as-number
                                        
    • To add an EBGP neighbor, configure the as-number parameter with a number different from the BGP as-number configured in the router bgp as-number command.
    • To add an IBGP neighbor, configure the as-number parameter with the same BGP as-number configured in the router bgp as-number command.
  5. Assign a peer-template with a peer-group name from which to inherit to the neighbor in ROUTER-NEIGHBOR mode.
    inherit template 
                                           template-name
                                        
  6. Enable the neighbor in ROUTER-BGP mode.
    neighbor 
                                           ip-address
                                        
  7. Enable the peer-group in ROUTER-NEIGHBOR mode.
    no shutdown
When you add a peer to a peer group, it inherits all the peer group configured parameters. When you disable a peer group, all the peers within the peer template that are in the Established state move to the Idle state. A neighbor cannot become a part of a peer group if it has any of these commands configured:
  • advertisement-interval
  • next-hop-self
  • route-map out
  • route-reflector-client
  • send-community

A neighbor may keep its configuration after it is added to a peer group if the neighbor configuration is more specific than the peer group and if the neighbor configuration does not affect outgoing updates.

To display the peer-group configuration assigned to a BGP neighbor, enter the show ip bgp peer-group peer-group-name command. The show ip bgp neighbor command output does not display peer-group configurations.

Configure peer templates

OS10(config)# router bgp 300
                                 OS10(config-router-bgp-300)# template ebgppg
                                 OS10(config-router-template)# remote-as 100
                                 OS10(config-router-template)# exit
                                 OS10(config-router-bgp-300)# neighbor 3.1.1.1
                                 OS10(config-router-neighbor)# inherit template ebgppg
                                 OS10(config-router-neighbor)# no shutdown
                              

View peer group status

OS10(config-router-neighbor)# do show ip bgp peer-group ebgppg
                                 Peer-group ebgppg, remote AS 100
                                 BGP version 4
                                 Minimum time between advertisement runs is 30 seconds
                                 For address family:  Unicast
                                 BGP neighbor is ebgppg, peer-group external
                                 Update packing has 4_OCTET_AS support enabled
                                 
                                 Number of peers in this group 1
                                 Peer-group members:
                              

View running configuration

OS10(config-router-neighbor)# do show running-configuration bgp
                                 !
                                 router bgp 300
                                 !
                                 neighbor 3.1.1.1
                                 inherit template ebgppg
                                 no shutdown
                                 !
                                 template ebgppg
                                 remote-as 100
                              

Rate this content

Accurate
Useful
Easy to understand
Was this article helpful?
0/3000 characters
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please provide ratings (1-5 stars).
  Please select whether the article was helpful or not.
  Comments cannot contain these special characters: <>()\