def GetNodeInfo(vgname):
- """ gives back a hash with different informations
- about the node
+ """Gives back a hash with different informations about the node.
Returns:
{ 'vg_size' : xxx, 'vg_free' : xxx, 'memory_domain0': xxx,
def ListVolumeGroups():
- """List the volume groups and their size
+ """List the volume groups and their size.
Returns:
Dictionary with keys volume name and values the size of the volume
def BridgesExist(bridges_list):
- """Check if a list of bridges exist on the current node
+ """Check if a list of bridges exist on the current node.
Returns:
True if all of them exist, false otherwise
def GetInstanceList():
- """ provides a list of instances
+ """Provides a list of instances.
Returns:
A list of all running instances on the current node
def GetInstanceInfo(instance):
- """ gives back the informations about an instance
- as a dictonary
+ """Gives back the informations about an instance as a dictionary.
Args:
instance: name of the instance (ex. instance1.example.com)
def AddOSToInstance(instance, os_disk, swap_disk):
- """Add an os to an instance.
+ """Add an OS to an instance.
Args:
instance: the instance object
return None
def _OSOndiskVersion(name, os_dir):
- """Compute and return the api version of a given OS.
+ """Compute and return the API version of a given OS.
- This function will try to read the api version of the os given by
+ This function will try to read the API version of the os given by
the 'name' parameter and residing in the 'os_dir' directory.
Return value will be either an integer denoting the version or None in the
class Client:
"""RPC Client class.
- This class, given a (remote) ethod name, a list of parameters and a
+ This class, given a (remote) method name, a list of parameters and a
list of nodes, will contact (in parallel) all nodes, and return a
dict of results (key: node name, value: result).
def call_instance_start(node, instance, extra_args):
- """Stars an instance.
+ """Starts an instance.
This is a single-node call.