From 353230a17e91f65977706944202f52c8da4fe827 Mon Sep 17 00:00:00 2001 From: Farid Da Encarnacao Date: Tue, 7 Aug 2018 15:56:38 -0400 Subject: [PATCH] Clear all l3 related namespace before starting neutron-l3-agent only when l3_ha is enable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If we are not using l3 ha mode, it’s not necessary to delete the namespaces related to l3. It will speed up the start of the neutron l3 agent. Change-Id: I78f6d927a78e8f9e4ed855e4b6d1362bdfc6b985 Closes-Bug: #1785880 --- ansible/roles/neutron/templates/neutron-l3-agent-wrapper.sh.j2 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ansible/roles/neutron/templates/neutron-l3-agent-wrapper.sh.j2 b/ansible/roles/neutron/templates/neutron-l3-agent-wrapper.sh.j2 index ca28b279b7..2c0bb70259 100644 --- a/ansible/roles/neutron/templates/neutron-l3-agent-wrapper.sh.j2 +++ b/ansible/roles/neutron/templates/neutron-l3-agent-wrapper.sh.j2 @@ -2,12 +2,14 @@ set -o errexit +{% if enable_neutron_agent_ha | bool %} # NOTE(jeffrey4l): Remove all l3 related netns in case of multiple active routers in l3 high available mode. neutron-netns-cleanup \ --config-file /etc/neutron/neutron.conf \ --config-file /etc/neutron/l3_agent.ini \ --config-file /etc/neutron/fwaas_driver.ini \ --force --agent-type l3 +{% endif %} neutron-l3-agent \ --config-file /etc/neutron/neutron.conf \