Skip to content

Commit 1ae4db3

Browse files
Quagga: Use bgp keepalive and holdtime timers from configdb (#1661)
1 parent f3426e3 commit 1ae4db3

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

dockers/docker-fpm-quagga/bgpd.conf.j2

+5
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,11 @@ router bgp {{ DEVICE_METADATA['localhost']['bgp_asn'] }}
6464
{% if bgp_session['asn'] | int != 0 %}
6565
neighbor {{ neighbor_addr }} remote-as {{ bgp_session['asn'] }}
6666
neighbor {{ neighbor_addr }} description {{ bgp_session['name'] }}
67+
{# set the bgp neighbor timers if they have not default values #}
68+
{% if (bgp_session['keepalive'] is defined and bgp_session['keepalive'] | int != 60)
69+
or (bgp_session['holdtime'] is defined and bgp_session['holdtime'] | int != 180) %}
70+
neighbor {{ neighbor_addr }} timers {{ bgp_session['keepalive'] }} {{ bgp_session['holdtime'] }}
71+
{% endif %}
6772
{% if bgp_session.has_key('admin_status') and bgp_session['admin_status'] == 'down' or not bgp_session.has_key('admin_status') and DEVICE_METADATA['localhost'].has_key('default_bgp_status') and DEVICE_METADATA['localhost']['default_bgp_status'] == 'down' %}
6873
neighbor {{ neighbor_addr }} shutdown
6974
{% endif %}

0 commit comments

Comments
 (0)