Logo Search packages:      
Sourcecode: ganeti version File versions  Download package

def lib::config::ConfigWriter::VerifyConfig (   self  ) 

Stub verify function.

Definition at line 159 of file config.py.

00159                         :
    """Stub verify function.
    """
    self._OpenConfig()
    self._ReleaseLock()

    result = []
    seen_macs = []
    data = self._config_data
    for instance_name in data.instances:
      instance = data.instances[instance_name]
      if instance.primary_node not in data.nodes:
        result.append("instance '%s' has invalid primary node '%s'" %
                      (instance_name, instance.primary_node))
      for snode in instance.secondary_nodes:
        if snode not in data.nodes:
          result.append("instance '%s' has invalid secondary node '%s'" %
                        (instance_name, snode))
      for idx, nic in enumerate(instance.nics):
        if nic.mac in seen_macs:
          result.append("instance '%s' has NIC %d mac %s duplicate" %
                        (instance_name, idx, nic.mac))
        else:
          seen_macs.append(nic.mac)
    return result

  def SetDiskID(self, disk, node_name):


Generated by  Doxygen 1.6.0   Back to index