Revert the instance IP conflicts
authorIustin Pop <iustin@google.com>
Wed, 4 Nov 2009 13:14:53 +0000 (14:14 +0100)
committerIustin Pop <iustin@google.com>
Wed, 4 Nov 2009 13:32:15 +0000 (14:32 +0100)
Since instances can live in different VLANs from nodes (especially in
routed mode), based on the 'link' parameter, we shouldn't always
restrict having duplicate IPs. Thus we only check the node IPs/cluster
IP for now.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

lib/config.py

index 156acda..2fea523 100644 (file)
@@ -408,10 +408,6 @@ class ConfigWriter:
       _helper(node.primary_ip, "node:%s/primary" % node.name)
       if node.secondary_ip != node.primary_ip:
         _helper(node.secondary_ip, "node:%s/secondary" % node.name)
-    for instance in data.instances.values():
-      for idx, nic in enumerate(instance.nics):
-        if nic.ip is not None:
-          _helper(nic.ip, "instance:%s/nic:%d" % (instance.name, idx))
 
     for ip, owners in ips.items():
       if len(owners) > 1: