From 92f4c7708b4f55f225e13f85857092584955fb19 Mon Sep 17 00:00:00 2001 From: "Christopher H. Laco" Date: Fri, 14 Mar 2014 14:33:35 -0400 Subject: [PATCH] Enable send_arp_for_ha in l3_agent.ini send_arp_for_ha is defined for nova networks in the nova cookbook and referenced here but never templated for quantum/neutron l3_agent. - Add attribute for send_arp_for_ha_count in nova networks - Add attribute for send_arp_for_ha in quantum/neutron - Document new attributes in README - Template send_arp_for_ha in l3_agent.ini https://github.com/rcbops-cookbooks/nova will need to be updated following this change. See https://github.com/rcbops/chef-cookbooks/issues/877 --- README.md | 2 ++ attributes/default.rb | 2 ++ recipes/neutron-l3-agent.rb | 3 ++- templates/default/l3_agent.ini.erb | 2 ++ 4 files changed, 8 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 13da8cd..7f5bbf9 100644 --- a/README.md +++ b/README.md @@ -75,6 +75,7 @@ Nova Networking * `nova["network"]["dhcp_domain"]` - Domain to use for building hostnames * `nova["network"]["force_dhcp_release"]` - Send DHCP release on instance termination? * `nova["network"]["send_arp_for_ha"]` - Send gratuitous ARPs for HA setup? +* `nova["network"]["send_arp_for_ha_count"]` - Number of gratuitous ARPs to send. defaults to 3 * `nova["network"]["auto_assign_floating_ip"]` - Auto-assigning floating ip to VM? * `nova["network"]["floating_pool_name"]` - if creating a floating ip pool, what to name it * `nova["network"]["multi_host"]` - Use multi-host mode? @@ -88,6 +89,7 @@ Neutron Networking * `neutron["linuxnet_interface_driver"]` - used in nova.conf. the linux net interface driver, by default nova.network.linux_net.LinuxOVSInterfaceDriver * `neutron["firewall_driver"]` - used in nova.conf. the firewall driver to use, by default nova.virt.libvirt.firewall.IptablesFirewallDriver * `neutron["agent_down_time"]` - Seconds elapsed until an agent is considered down +* `neutron["send_arp_for_ha"]` - Number of gratuitous ARPs to send. defaults to 3. 0 disables arps completely. * `neutron["services"]["api"]["scheme"]` - scheme for service (http/https) * `neutron["services"]["api"]["network"]` - `osops_networks` network name which service operates on * `neutron["services"]["api"]["port"]` - port service binds to diff --git a/attributes/default.rb b/attributes/default.rb index f63bd6e..5db1063 100644 --- a/attributes/default.rb +++ b/attributes/default.rb @@ -47,6 +47,7 @@ default["nova"]["network"]["dhcp_domain"] = "novalocal" default["nova"]["network"]["force_dhcp_release"] = true default["nova"]["network"]["send_arp_for_ha"] = true +default['nova']["network"]["send_arp_for_ha_count"] = 3 default["nova"]["network"]["auto_assign_floating_ip"] = false default["nova"]["network"]["floating_pool_name"] = "nova" default["nova"]["network"]["multi_host"] = true @@ -76,6 +77,7 @@ "nova.network.linux_net.LinuxOVSInterfaceDriver" default["neutron"]["firewall_driver"] = "nova.virt.firewall.NoopFirewallDriver" +default['neutron']["send_arp_for_ha"] = 3 # Set the notification Driver # Options are no_op, rpc, log, rabbit diff --git a/recipes/neutron-l3-agent.rb b/recipes/neutron-l3-agent.rb index fbe5de8..ea6fa43 100644 --- a/recipes/neutron-l3-agent.rb +++ b/recipes/neutron-l3-agent.rb @@ -69,7 +69,8 @@ variables( "neutron_external_bridge" => node["neutron"][plugin]["external_bridge"], "nova_metadata_ip" => metadata_ip, - "neutron_plugin" => node["neutron"]["plugin"] + "neutron_plugin" => node["neutron"]["plugin"], + "send_arp_for_ha" => node["neutron"]["send_arp_for_ha"] ) notifies :restart, "service[neutron-l3-agent]", :delayed notifies :enable, "service[neutron-l3-agent]", :delayed diff --git a/templates/default/l3_agent.ini.erb b/templates/default/l3_agent.ini.erb index 45c3420..c2c9ce5 100644 --- a/templates/default/l3_agent.ini.erb +++ b/templates/default/l3_agent.ini.erb @@ -4,6 +4,8 @@ external_network_bridge = <%= @neutron_external_bridge %> metadata_ip = <%= @nova_metadata_ip %> metadata_port = 8775 +send_arp_for_ha = <%= @send_arp_for_ha %> + <% if @neutron_plugin == "ovs" %> # OVS interface_driver = neutron.agent.linux.interface.OVSInterfaceDriver