Skip to content

Commit 3213244

Browse files
abdosimssonicbld
authored andcommitted
[chassis/multi-asic] Enable Sending BGP Community over internal neighbors over iBGP Session (sonic-net#16705)
What I did: Enable Sending BGP Community over internal neighbors over iBGP Session Microsoft ADO: 25268695 Why I did: Without this change BGP community send by e-BGP Peers are not carry-forward to other e-BGP peers. str2-xxxx-lc1-2# show bgp ipv6 20c0:a801::/64 BGP routing table entry for 20c0:a801::/64, version 52141 Paths: (1 available, best sonic-net#1, table default) Not advertised to any peer 65000 65500 2603:10e2:400::6 from 2603:10e2:400::6 (3.3.3.6) Origin IGP, localpref 100, valid, internal, best (First path received) Last update: Tue Sep 26 16:08:26 2023 str2-xxxx-lc1-2# show ip bgp 192.168.35.128/25 BGP routing table entry for 192.168.35.128/25, version 52688 Paths: (1 available, best sonic-net#1, table default) Not advertised to any peer 65000 65502 3.3.3.6 from 3.3.3.6 (3.3.3.6) Origin IGP, localpref 100, valid, internal, best (First path received) Last update: Tue Sep 26 15:45:51 2023 After the change str2-xxxx-lc2-2(config)# router bgp 65100 str2-xxxx-lc2-2(config-router)# address-family ipv4 str2-xxxx-lc2-2(config-router-af)# neighbor INTERNAL_PEER_V4 send-community str2-xxxx-lc2-2(config-router-af)# exit str2-xxxx-lc2-2(config-router)# address-family ipv6 str2-xxxx-lc2-2(config-router-af)# neighbor INTERNAL_PEER_V6 send-community str2-xxxx-lc1-2# show bgp ipv6 20c0:a801::/64 BGP routing table entry for 20c0:a801::/64, version 52400 Paths: (1 available, best sonic-net#1, table default) Not advertised to any peer 65000 65500 2603:10e2:400::6 from 2603:10e2:400::6 (3.3.3.6) Origin IGP, localpref 100, valid, internal, best (First path received) **Community: 1111:1111** Last update: Tue Sep 26 16:10:19 2023 str2-xxxx-lc1-2# show ip bgp 192.168.35.128/25 BGP routing table entry for 192.168.35.128/25, version 52947 Paths: (1 available, best sonic-net#1, table default) Not advertised to any peer 65000 65502 3.3.3.6 from 3.3.3.6 (3.3.3.6) Origin IGP, localpref 100, valid, internal, best (First path received) **Community: 1111:1111** Last update: Tue Sep 26 16:10:09 2023 Signed-off-by: Abhishek Dosi <[email protected]>
1 parent 5c78719 commit 3213244

File tree

7 files changed

+14
-0
lines changed

7 files changed

+14
-0
lines changed

dockers/docker-fpm-frr/frr/bgpd/templates/internal/peer-group.conf.j2

+2
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
neighbor INTERNAL_PEER_V4 allowas-in 1
1515
neighbor INTERNAL_PEER_V4 route-map FROM_BGP_INTERNAL_PEER_V4 in
1616
neighbor INTERNAL_PEER_V4 route-map TO_BGP_INTERNAL_PEER_V4 out
17+
neighbor INTERNAL_PEER_V4 send-community
1718
exit-address-family
1819
{% if CONFIG_DB__DEVICE_METADATA['localhost']['switch_type'] == 'chassis-packet' %}
1920
neighbor INTERNAL_PEER_V6 update-source Loopback4096
@@ -26,6 +27,7 @@
2627
neighbor INTERNAL_PEER_V6 allowas-in 1
2728
neighbor INTERNAL_PEER_V6 route-map FROM_BGP_INTERNAL_PEER_V6 in
2829
neighbor INTERNAL_PEER_V6 route-map TO_BGP_INTERNAL_PEER_V6 out
30+
neighbor INTERNAL_PEER_V6 send-community
2931
exit-address-family
3032
!
3133
! end of template: bgpd/templates/internal/peer-group.conf.j2

dockers/docker-fpm-frr/frr/bgpd/templates/voq_chassis/peer-group.conf.j2

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
neighbor VOQ_CHASSIS_V4_PEER soft-reconfiguration inbound
1313
neighbor VOQ_CHASSIS_V4_PEER route-map FROM_VOQ_CHASSIS_V4_PEER in
1414
neighbor VOQ_CHASSIS_V4_PEER route-map TO_VOQ_CHASSIS_V4_PEER out
15+
neighbor VOQ_CHASSIS_V4_PEER send-community
1516
exit-address-family
1617
address-family ipv6
1718
{% if CONFIG_DB__DEVICE_METADATA['localhost']['type'] == 'ToRRouter' %}
@@ -22,6 +23,7 @@
2223
neighbor VOQ_CHASSIS_V6_PEER soft-reconfiguration inbound
2324
neighbor VOQ_CHASSIS_V6_PEER route-map FROM_VOQ_CHASSIS_V6_PEER in
2425
neighbor VOQ_CHASSIS_V6_PEER route-map TO_VOQ_CHASSIS_V6_PEER out
26+
neighbor VOQ_CHASSIS_V6_PEER send-community
2527
exit-address-family
2628
!
2729
! end of template: bgpd/templates/voq_chassis/peer-group.conf.j2

src/sonic-bgpcfgd/tests/data/internal/peer-group.conf/result_back.conf

+2
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,15 @@
99
neighbor INTERNAL_PEER_V4 allowas-in 1
1010
neighbor INTERNAL_PEER_V4 route-map FROM_BGP_INTERNAL_PEER_V4 in
1111
neighbor INTERNAL_PEER_V4 route-map TO_BGP_INTERNAL_PEER_V4 out
12+
neighbor INTERNAL_PEER_V4 send-community
1213
exit-address-family
1314
address-family ipv6
1415
neighbor INTERNAL_PEER_V6 route-reflector-client
1516
neighbor INTERNAL_PEER_V6 soft-reconfiguration inbound
1617
neighbor INTERNAL_PEER_V6 allowas-in 1
1718
neighbor INTERNAL_PEER_V6 route-map FROM_BGP_INTERNAL_PEER_V6 in
1819
neighbor INTERNAL_PEER_V6 route-map TO_BGP_INTERNAL_PEER_V6 out
20+
neighbor INTERNAL_PEER_V6 send-community
1921
exit-address-family
2022
!
2123
! end of template: bgpd/templates/internal/peer-group.conf.j2

src/sonic-bgpcfgd/tests/data/internal/peer-group.conf/result_chasiss_packet.conf

+2
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,15 @@
99
neighbor INTERNAL_PEER_V4 allowas-in 1
1010
neighbor INTERNAL_PEER_V4 route-map FROM_BGP_INTERNAL_PEER_V4 in
1111
neighbor INTERNAL_PEER_V4 route-map TO_BGP_INTERNAL_PEER_V4 out
12+
neighbor INTERNAL_PEER_V4 send-community
1213
exit-address-family
1314
neighbor INTERNAL_PEER_V6 update-source Loopback4096
1415
address-family ipv6
1516
neighbor INTERNAL_PEER_V6 soft-reconfiguration inbound
1617
neighbor INTERNAL_PEER_V6 allowas-in 1
1718
neighbor INTERNAL_PEER_V6 route-map FROM_BGP_INTERNAL_PEER_V6 in
1819
neighbor INTERNAL_PEER_V6 route-map TO_BGP_INTERNAL_PEER_V6 out
20+
neighbor INTERNAL_PEER_V6 send-community
1921
exit-address-family
2022
!
2123
! end of template: bgpd/templates/internal/peer-group.conf.j2

src/sonic-bgpcfgd/tests/data/internal/peer-group.conf/result_front.conf

+2
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,14 @@
88
neighbor INTERNAL_PEER_V4 allowas-in 1
99
neighbor INTERNAL_PEER_V4 route-map FROM_BGP_INTERNAL_PEER_V4 in
1010
neighbor INTERNAL_PEER_V4 route-map TO_BGP_INTERNAL_PEER_V4 out
11+
neighbor INTERNAL_PEER_V4 send-community
1112
exit-address-family
1213
address-family ipv6
1314
neighbor INTERNAL_PEER_V6 soft-reconfiguration inbound
1415
neighbor INTERNAL_PEER_V6 allowas-in 1
1516
neighbor INTERNAL_PEER_V6 route-map FROM_BGP_INTERNAL_PEER_V6 in
1617
neighbor INTERNAL_PEER_V6 route-map TO_BGP_INTERNAL_PEER_V6 out
18+
neighbor INTERNAL_PEER_V6 send-community
1719
exit-address-family
1820
!
1921
! end of template: bgpd/templates/internal/peer-group.conf.j2

src/sonic-bgpcfgd/tests/data/voq_chassis/peer-group.conf/result_all.conf

+2
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
neighbor VOQ_CHASSIS_V4_PEER soft-reconfiguration inbound
1111
neighbor VOQ_CHASSIS_V4_PEER route-map FROM_VOQ_CHASSIS_V4_PEER in
1212
neighbor VOQ_CHASSIS_V4_PEER route-map TO_VOQ_CHASSIS_V4_PEER out
13+
neighbor VOQ_CHASSIS_V4_PEER send-community
1314
exit-address-family
1415
address-family ipv6
1516
neighbor VOQ_CHASSIS_V6_PEER allowas-in 1
@@ -18,6 +19,7 @@
1819
neighbor VOQ_CHASSIS_V6_PEER soft-reconfiguration inbound
1920
neighbor VOQ_CHASSIS_V6_PEER route-map FROM_VOQ_CHASSIS_V6_PEER in
2021
neighbor VOQ_CHASSIS_V6_PEER route-map TO_VOQ_CHASSIS_V6_PEER out
22+
neighbor VOQ_CHASSIS_V6_PEER send-community
2123
exit-address-family
2224
!
2325
! end of template: bgpd/templates/voq_chassis/peer-group.conf.j2

src/sonic-bgpcfgd/tests/data/voq_chassis/peer-group.conf/result_base.conf

+2
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,15 @@
99
neighbor VOQ_CHASSIS_V4_PEER soft-reconfiguration inbound
1010
neighbor VOQ_CHASSIS_V4_PEER route-map FROM_VOQ_CHASSIS_V4_PEER in
1111
neighbor VOQ_CHASSIS_V4_PEER route-map TO_VOQ_CHASSIS_V4_PEER out
12+
neighbor VOQ_CHASSIS_V4_PEER send-community
1213
exit-address-family
1314
address-family ipv6
1415
neighbor VOQ_CHASSIS_V6_PEER activate
1516
neighbor VOQ_CHASSIS_V6_PEER addpath-tx-all-paths
1617
neighbor VOQ_CHASSIS_V6_PEER soft-reconfiguration inbound
1718
neighbor VOQ_CHASSIS_V6_PEER route-map FROM_VOQ_CHASSIS_V6_PEER in
1819
neighbor VOQ_CHASSIS_V6_PEER route-map TO_VOQ_CHASSIS_V6_PEER out
20+
neighbor VOQ_CHASSIS_V6_PEER send-community
1921
exit-address-family
2022
!
2123
! end of template: bgpd/templates/voq_chassis/peer-group.conf.j2

0 commit comments

Comments
 (0)