]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
remove default value of local_ip in OVS agent
authorMark McClain <mark.mcclain@dreamhost.com>
Mon, 17 Sep 2012 21:28:00 +0000 (17:28 -0400)
committerMark McClain <mark.mcclain@dreamhost.com>
Fri, 21 Sep 2012 20:53:08 +0000 (16:53 -0400)
fixes bug 1051744

Remove the default value for local_ip in the OVS agent config.

Change-Id: Ie23ba8510c0cf5c17443c805e0befce6eccb253c

etc/quantum/plugins/openvswitch/ovs_quantum_plugin.ini
quantum/plugins/openvswitch/agent/ovs_quantum_agent.py
quantum/plugins/openvswitch/common/config.py

index 3b1e844890cf1c22ca51d936b3527f3cfc506e2e..4b46a8316b13e591b8ced126147cb5251a68f4da 100644 (file)
@@ -64,7 +64,7 @@ reconnect_interval = 2
 # empty for the server. Set local-ip to be the local IP address of
 # this hypervisor.
 #
-# Default: local_ip = 10.0.0.3
+# Default: local_ip =
 
 # (ListOpt) Comma-separated list of <physical_network>:<bridge> tuples
 # mapping physical network names to the agent's node-specific OVS
index c488e824041587746c75411c151f999906e0f659..da03ea673996eed5d6734bf3af612dd90a875c06 100755 (executable)
@@ -802,6 +802,10 @@ def main():
     local_ip = cfg.CONF.OVS.local_ip
     enable_tunneling = cfg.CONF.OVS.enable_tunneling
 
+    if enable_tunneling and not local_ip:
+        LOG.error("Invalid local_ip. (%s)" % repr(local_ip))
+        sys.exit(1)
+
     bridge_mappings = {}
     for mapping in cfg.CONF.OVS.bridge_mappings:
         mapping = mapping.strip()
index 61be65a78ae0d04b2ad37ae9e2175f876d5a1550..5de151acb81982c6d6f524606929a822942f6909 100644 (file)
@@ -31,7 +31,7 @@ ovs_opts = [
     cfg.StrOpt('integration_bridge', default='br-int'),
     cfg.BoolOpt('enable_tunneling', default=False),
     cfg.StrOpt('tunnel_bridge', default='br-tun'),
-    cfg.StrOpt('local_ip', default='10.0.0.3'),
+    cfg.StrOpt('local_ip', default=''),
     cfg.ListOpt('bridge_mappings',
                 default=DEFAULT_BRIDGE_MAPPINGS,
                 help="List of <physical_network>:<bridge>"),