[bgp]: Reduce bgp connect retry timer to 10 seconds (#7169)

The default bgp connect retry timer is 120 seconds. A reconnection will happen 120 seconds if the initial connection fails. This PR aims to allow a more frequent retry.
This commit is contained in:
Shi Su 2021-03-27 11:36:56 -07:00 committed by Danny Allen
parent 567eae6116
commit 576864b769
10 changed files with 10 additions and 0 deletions

View File

@ -8,6 +8,7 @@
or (bgp_session['holdtime'] is defined and bgp_session['holdtime'] | int != 180) %} or (bgp_session['holdtime'] is defined and bgp_session['holdtime'] | int != 180) %}
neighbor {{ neighbor_addr }} timers {{ bgp_session['keepalive'] | default("60") }} {{ bgp_session['holdtime'] | default("180") }} neighbor {{ neighbor_addr }} timers {{ bgp_session['keepalive'] | default("60") }} {{ bgp_session['holdtime'] | default("180") }}
{% endif %} {% endif %}
neighbor {{ neighbor_addr }} timers connect 10
! !
{% if 'admin_status' in bgp_session and bgp_session['admin_status'] == 'down' or 'admin_status' not in bgp_session and 'default_bgp_status' in CONFIG_DB__DEVICE_METADATA['localhost'] and CONFIG_DB__DEVICE_METADATA['localhost']['default_bgp_status'] == 'down' %} {% if 'admin_status' in bgp_session and bgp_session['admin_status'] == 'down' or 'admin_status' not in bgp_session and 'default_bgp_status' in CONFIG_DB__DEVICE_METADATA['localhost'] and CONFIG_DB__DEVICE_METADATA['localhost']['default_bgp_status'] == 'down' %}
neighbor {{ neighbor_addr }} shutdown neighbor {{ neighbor_addr }} shutdown

View File

@ -4,6 +4,7 @@
neighbor 10.10.10.10 remote-as 555 neighbor 10.10.10.10 remote-as 555
neighbor 10.10.10.10 description remote_peer neighbor 10.10.10.10 description remote_peer
neighbor 10.10.10.10 timers 5 30 neighbor 10.10.10.10 timers 5 30
neighbor 10.10.10.10 timers connect 10
neighbor 10.10.10.10 shutdown neighbor 10.10.10.10 shutdown
address-family ipv4 address-family ipv4
neighbor 10.10.10.10 peer-group PEER_V4 neighbor 10.10.10.10 peer-group PEER_V4

View File

@ -4,6 +4,7 @@
neighbor fc::10 remote-as 555 neighbor fc::10 remote-as 555
neighbor fc::10 description remote_peer neighbor fc::10 description remote_peer
neighbor fc::10 timers 5 30 neighbor fc::10 timers 5 30
neighbor fc::10 timers connect 10
neighbor fc::10 shutdown neighbor fc::10 shutdown
address-family ipv6 address-family ipv6
neighbor fc::10 peer-group PEER_V6 neighbor fc::10 peer-group PEER_V6

View File

@ -3,6 +3,7 @@
! !
neighbor 10.10.10.10 remote-as 555 neighbor 10.10.10.10 remote-as 555
neighbor 10.10.10.10 description remote_peer neighbor 10.10.10.10 description remote_peer
neighbor 10.10.10.10 timers connect 10
address-family ipv4 address-family ipv4
neighbor 10.10.10.10 peer-group PEER_V4 neighbor 10.10.10.10 peer-group PEER_V4
neighbor 10.10.10.10 activate neighbor 10.10.10.10 activate

View File

@ -3,6 +3,7 @@
! !
neighbor fc00::2 remote-as 555 neighbor fc00::2 remote-as 555
neighbor fc00::2 description remote_peer neighbor fc00::2 description remote_peer
neighbor fc00::2 timers connect 10
address-family ipv6 address-family ipv6
neighbor fc00::2 peer-group PEER_V6 neighbor fc00::2 peer-group PEER_V6
neighbor fc00::2 activate neighbor fc00::2 activate

View File

@ -3,6 +3,7 @@
! !
neighbor 10.10.10.10 remote-as 555 neighbor 10.10.10.10 remote-as 555
neighbor 10.10.10.10 description remote_peer neighbor 10.10.10.10 description remote_peer
neighbor 10.10.10.10 timers connect 10
address-family ipv4 address-family ipv4
neighbor 10.10.10.10 peer-group PEER_V4 neighbor 10.10.10.10 peer-group PEER_V4
neighbor 10.10.10.10 activate neighbor 10.10.10.10 activate

View File

@ -3,6 +3,7 @@
! !
neighbor 10.10.10.10 remote-as 555 neighbor 10.10.10.10 remote-as 555
neighbor 10.10.10.10 description remote_peer neighbor 10.10.10.10 description remote_peer
neighbor 10.10.10.10 timers connect 10
neighbor 10.10.10.10 shutdown neighbor 10.10.10.10 shutdown
address-family ipv4 address-family ipv4
neighbor 10.10.10.10 peer-group PEER_V4 neighbor 10.10.10.10 peer-group PEER_V4

View File

@ -3,6 +3,7 @@
! !
neighbor 10.10.10.10 remote-as 555 neighbor 10.10.10.10 remote-as 555
neighbor 10.10.10.10 description remote_peer neighbor 10.10.10.10 description remote_peer
neighbor 10.10.10.10 timers connect 10
address-family ipv4 address-family ipv4
neighbor 10.10.10.10 peer-group PEER_V4 neighbor 10.10.10.10 peer-group PEER_V4
neighbor 10.10.10.10 activate neighbor 10.10.10.10 activate

View File

@ -4,6 +4,7 @@
neighbor 10.10.10.10 remote-as 555 neighbor 10.10.10.10 remote-as 555
neighbor 10.10.10.10 description remote_peer neighbor 10.10.10.10 description remote_peer
neighbor 10.10.10.10 timers 5 180 neighbor 10.10.10.10 timers 5 180
neighbor 10.10.10.10 timers connect 10
address-family ipv4 address-family ipv4
neighbor 10.10.10.10 peer-group PEER_V4 neighbor 10.10.10.10 peer-group PEER_V4
neighbor 10.10.10.10 activate neighbor 10.10.10.10 activate

View File

@ -4,6 +4,7 @@
neighbor 10.10.10.10 remote-as 555 neighbor 10.10.10.10 remote-as 555
neighbor 10.10.10.10 description remote_peer neighbor 10.10.10.10 description remote_peer
neighbor 10.10.10.10 timers 60 240 neighbor 10.10.10.10 timers 60 240
neighbor 10.10.10.10 timers connect 10
address-family ipv4 address-family ipv4
neighbor 10.10.10.10 peer-group PEER_V4 neighbor 10.10.10.10 peer-group PEER_V4
neighbor 10.10.10.10 activate neighbor 10.10.10.10 activate