Template change for BGP monitors on T2 (#14844)
Why I did it To support BGPMon sessions from each T2 linecard ASIC Work item tracking Microsoft ADO (number only): 17873174 How I did it Added change in BGPMon configuration to use Loopback4096 as source interface, since this has a unique IP per ASIC. How to verify it Tested by manually setting up BGPMon session on T2 LC and verified that Loopback4096 could be used as source
This commit is contained in:
parent
b6b31df339
commit
4e60f0d563
@ -2,11 +2,30 @@
|
|||||||
! template: bgpd/templates/BGPMON/peer-group.conf.j2
|
! template: bgpd/templates/BGPMON/peer-group.conf.j2
|
||||||
!
|
!
|
||||||
neighbor BGPMON peer-group
|
neighbor BGPMON peer-group
|
||||||
|
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'SpineRouter' %}
|
||||||
|
neighbor BGPMON update-source Loopback4096
|
||||||
|
{% else %}
|
||||||
neighbor BGPMON update-source {{ loopback0_ipv4 | ip }}
|
neighbor BGPMON update-source {{ loopback0_ipv4 | ip }}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
address-family ipv4
|
||||||
|
neighbor BGPMON activate
|
||||||
neighbor BGPMON route-map FROM_BGPMON in
|
neighbor BGPMON route-map FROM_BGPMON in
|
||||||
neighbor BGPMON route-map TO_BGPMON out
|
neighbor BGPMON route-map TO_BGPMON out
|
||||||
neighbor BGPMON send-community
|
neighbor BGPMON send-community
|
||||||
neighbor BGPMON maximum-prefix 1
|
neighbor BGPMON maximum-prefix 1
|
||||||
|
exit-address-family
|
||||||
|
|
||||||
|
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'SpineRouter' %}
|
||||||
|
address-family ipv6
|
||||||
|
neighbor BGPMON activate
|
||||||
|
neighbor BGPMON route-map FROM_BGPMON in
|
||||||
|
neighbor BGPMON route-map TO_BGPMON out
|
||||||
|
neighbor BGPMON send-community
|
||||||
|
neighbor BGPMON maximum-prefix 1
|
||||||
|
exit-address-family
|
||||||
|
{% endif %}
|
||||||
!
|
!
|
||||||
! end of template: bgpd/templates/BGPMON/peer-group.conf.j2
|
! end of template: bgpd/templates/BGPMON/peer-group.conf.j2
|
||||||
!
|
!
|
||||||
|
|
||||||
|
@ -12,6 +12,7 @@ vni {{ vnet_metadata['vni'] }}
|
|||||||
{% block interfaces %}
|
{% block interfaces %}
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
{% for (name, prefix) in INTERFACE|pfx_filter %}
|
{% for (name, prefix) in INTERFACE|pfx_filter %}
|
||||||
interface {{ name }}
|
interface {{ name }}
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
{
|
{
|
||||||
|
"CONFIG_DB__DEVICE_METADATA": {
|
||||||
|
"localhost": {
|
||||||
|
"type": "LeafRouter"
|
||||||
|
}
|
||||||
|
},
|
||||||
"loopback0_ipv4": "1.1.1.1/32"
|
"loopback0_ipv4": "1.1.1.1/32"
|
||||||
}
|
}
|
@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"CONFIG_DB__DEVICE_METADATA": {
|
||||||
|
"localhost": {
|
||||||
|
"type": "SpineRouter"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -3,10 +3,14 @@
|
|||||||
!
|
!
|
||||||
neighbor BGPMON peer-group
|
neighbor BGPMON peer-group
|
||||||
neighbor BGPMON update-source 1.1.1.1
|
neighbor BGPMON update-source 1.1.1.1
|
||||||
|
address-family ipv4
|
||||||
|
neighbor BGPMON activate
|
||||||
neighbor BGPMON route-map FROM_BGPMON in
|
neighbor BGPMON route-map FROM_BGPMON in
|
||||||
neighbor BGPMON route-map TO_BGPMON out
|
neighbor BGPMON route-map TO_BGPMON out
|
||||||
neighbor BGPMON send-community
|
neighbor BGPMON send-community
|
||||||
neighbor BGPMON maximum-prefix 1
|
neighbor BGPMON maximum-prefix 1
|
||||||
|
exit-address-family
|
||||||
!
|
!
|
||||||
! end of template: bgpd/templates/BGPMON/peer-group.conf.j2
|
! end of template: bgpd/templates/BGPMON/peer-group.conf.j2
|
||||||
!
|
!
|
||||||
|
|
||||||
|
@ -0,0 +1,22 @@
|
|||||||
|
!
|
||||||
|
! template: bgpd/templates/BGPMON/peer-group.conf.j2
|
||||||
|
!
|
||||||
|
neighbor BGPMON peer-group
|
||||||
|
neighbor BGPMON update-source Loopback4096
|
||||||
|
address-family ipv4
|
||||||
|
neighbor BGPMON activate
|
||||||
|
neighbor BGPMON route-map FROM_BGPMON in
|
||||||
|
neighbor BGPMON route-map TO_BGPMON out
|
||||||
|
neighbor BGPMON send-community
|
||||||
|
neighbor BGPMON maximum-prefix 1
|
||||||
|
exit-address-family
|
||||||
|
address-family ipv6
|
||||||
|
neighbor BGPMON activate
|
||||||
|
neighbor BGPMON route-map FROM_BGPMON in
|
||||||
|
neighbor BGPMON route-map TO_BGPMON out
|
||||||
|
neighbor BGPMON send-community
|
||||||
|
neighbor BGPMON maximum-prefix 1
|
||||||
|
exit-address-family
|
||||||
|
!
|
||||||
|
! end of template: bgpd/templates/BGPMON/peer-group.conf.j2
|
||||||
|
!
|
@ -17,6 +17,7 @@ agentx
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface Ethernet0
|
interface Ethernet0
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface Ethernet0
|
interface Ethernet0
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -28,6 +28,7 @@ vni 20
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface Ethernet0
|
interface Ethernet0
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -20,6 +20,7 @@ agentx
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface PortChannel03
|
interface PortChannel03
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -26,6 +26,7 @@ vni 9000
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface Ethernet8
|
interface Ethernet8
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -26,6 +26,7 @@ vni 8000
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface Ethernet8
|
interface Ethernet8
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -23,6 +23,7 @@ log facility local4
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface PortChannel03
|
interface PortChannel03
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -20,6 +20,7 @@ agentx
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface PortChannel01
|
interface PortChannel01
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -26,6 +26,7 @@ vni 9000
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface Ethernet0
|
interface Ethernet0
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -26,6 +26,7 @@ vni 8000
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface Ethernet0
|
interface Ethernet0
|
||||||
link-detect
|
link-detect
|
||||||
|
@ -23,6 +23,7 @@ log facility local4
|
|||||||
!
|
!
|
||||||
! Enable nht through default route
|
! Enable nht through default route
|
||||||
ip nht resolve-via-default
|
ip nht resolve-via-default
|
||||||
|
ipv6 nht resolve-via-default
|
||||||
! Enable link-detect (default disabled)
|
! Enable link-detect (default disabled)
|
||||||
interface PortChannel01
|
interface PortChannel01
|
||||||
link-detect
|
link-detect
|
||||||
|
Loading…
Reference in New Issue
Block a user