diff --git a/dockers/docker-fpm-frr/docker_init.sh b/dockers/docker-fpm-frr/docker_init.sh index e24585945cc..f5d855f5784 100755 --- a/dockers/docker-fpm-frr/docker_init.sh +++ b/dockers/docker-fpm-frr/docker_init.sh @@ -49,6 +49,10 @@ write_default_zebra_config() echo "no fpm use-next-hop-groups" >> $FILE_NAME echo "fpm address 127.0.0.1" >> $FILE_NAME } + + grep -q '^no zebra nexthop kernel enable' $FILE_NAME || { + echo "no zebra nexthop kernel enable" >> $FILE_NAME + } } if [[ ! -z "$NAMESPACE_ID" ]]; then diff --git a/dockers/docker-fpm-frr/frr/zebra/zebra.conf.j2 b/dockers/docker-fpm-frr/frr/zebra/zebra.conf.j2 index 759cd2f8c38..128bc9c5870 100644 --- a/dockers/docker-fpm-frr/frr/zebra/zebra.conf.j2 +++ b/dockers/docker-fpm-frr/frr/zebra/zebra.conf.j2 @@ -7,6 +7,8 @@ {% endblock banner %} ! {% block fpm %} +! Force disable next hop group support +no zebra nexthop kernel enable {% if ( ('localhost' in DEVICE_METADATA) and ('nexthop_group' in DEVICE_METADATA['localhost']) and (DEVICE_METADATA['localhost']['nexthop_group'] == 'enabled') ) %} ! enable next hop group support diff --git a/platform/vs/docker-sonic-vs/frr/zebra.conf b/platform/vs/docker-sonic-vs/frr/zebra.conf index 695d339cdeb..9e3bd42315d 100644 --- a/platform/vs/docker-sonic-vs/frr/zebra.conf +++ b/platform/vs/docker-sonic-vs/frr/zebra.conf @@ -1,5 +1,4 @@ +no zebra nexthop kernel enable no fpm use-next-hop-groups - fpm address 127.0.0.1 zebra nexthop-group keep 1 - diff --git a/src/sonic-bgpcfgd/tests/data/sonic-cfggen/zebra/zebra.conf b/src/sonic-bgpcfgd/tests/data/sonic-cfggen/zebra/zebra.conf index c22fa8c7f93..23ef6d096b1 100644 --- a/src/sonic-bgpcfgd/tests/data/sonic-cfggen/zebra/zebra.conf +++ b/src/sonic-bgpcfgd/tests/data/sonic-cfggen/zebra/zebra.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-vni-zebra.conf b/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-vni-zebra.conf index 0761e4b2049..042f3ed16e3 100644 --- a/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-vni-zebra.conf +++ b/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-vni-zebra.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-zebra.conf b/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-zebra.conf index ad04eacbc8c..5eea029e8f8 100644 --- a/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-zebra.conf +++ b/src/sonic-config-engine/tests/sample_output/py2/t2-chassis-fe-zebra.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py2/zebra_frr.conf b/src/sonic-config-engine/tests/sample_output/py2/zebra_frr.conf index 129a98e3c23..01a101daa54 100644 --- a/src/sonic-config-engine/tests/sample_output/py2/zebra_frr.conf +++ b/src/sonic-config-engine/tests/sample_output/py2/zebra_frr.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py2/zebra_frr_dualtor.conf b/src/sonic-config-engine/tests/sample_output/py2/zebra_frr_dualtor.conf index a6cf1c42b07..e7898516bd5 100644 --- a/src/sonic-config-engine/tests/sample_output/py2/zebra_frr_dualtor.conf +++ b/src/sonic-config-engine/tests/sample_output/py2/zebra_frr_dualtor.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-vni-zebra.conf b/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-vni-zebra.conf index a238f3362ad..38e73e3ef29 100644 --- a/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-vni-zebra.conf +++ b/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-vni-zebra.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-zebra.conf b/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-zebra.conf index 55576c57349..d59b436e152 100644 --- a/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-zebra.conf +++ b/src/sonic-config-engine/tests/sample_output/py3/t2-chassis-fe-zebra.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py3/zebra_frr.conf b/src/sonic-config-engine/tests/sample_output/py3/zebra_frr.conf index dadb8972345..866d20a86ee 100644 --- a/src/sonic-config-engine/tests/sample_output/py3/zebra_frr.conf +++ b/src/sonic-config-engine/tests/sample_output/py3/zebra_frr.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups ! diff --git a/src/sonic-config-engine/tests/sample_output/py3/zebra_frr_dualtor.conf b/src/sonic-config-engine/tests/sample_output/py3/zebra_frr_dualtor.conf index 3bdb18fbc56..9885089b08a 100644 --- a/src/sonic-config-engine/tests/sample_output/py3/zebra_frr_dualtor.conf +++ b/src/sonic-config-engine/tests/sample_output/py3/zebra_frr_dualtor.conf @@ -4,6 +4,8 @@ ! file: zebra.conf ! ! +! Force disable next hop group support +no zebra nexthop kernel enable ! Uses the old known FPM behavior of including next hop information in the route (e.g. RTM_NEWROUTE) messages no fpm use-next-hop-groups !