class documentation

The server implementation.

This class holds all methods exposed over the RPC interface.

Class Method perspective_node_verify_light Run a light verify sequence on this node.
Static Method perspective_accept_instance Prepare the node to accept an instance.
Static Method perspective_all_instances_info Query information about all instances.
Static Method perspective_bdev_sizes Query the list of block devices
Static Method perspective_blockdev_addchildren Add a child to a mirror device.
Static Method perspective_blockdev_assemble Assemble a block device.
Static Method perspective_blockdev_close Closes the given block devices.
Static Method perspective_blockdev_convert Copy data from source block device to target.
Static Method perspective_blockdev_create Create a block device.
Static Method perspective_blockdev_find Expose the FindBlockDevice functionality for a disk.
Static Method perspective_blockdev_getdimensions Compute the sizes of the given block devices.
Static Method perspective_blockdev_getmirrorstatus Return the mirror status for a list of disks.
Static Method perspective_blockdev_getmirrorstatus_multi Return the mirror status for a list of disks.
Static Method perspective_blockdev_grow Grow a stack of devices.
Static Method perspective_blockdev_image Image a block device.
Static Method perspective_blockdev_open Opens the given block devices.
Static Method perspective_blockdev_pause_resume_sync Pause/resume sync of a block device.
Static Method perspective_blockdev_remove Remove a block device.
Static Method perspective_blockdev_removechildren Remove a child from a mirror device.
Static Method perspective_blockdev_rename Remove a block device.
Static Method perspective_blockdev_setinfo Sets metadata information on the given block device.
Static Method perspective_blockdev_shutdown Shutdown a block device.
Static Method perspective_blockdev_snapshot Create a snapshot device.
Static Method perspective_blockdev_wipe Wipe a block device.
Static Method perspective_bridges_exist Check if all bridges given exist on this node.
Static Method perspective_drbd_attach_net Attaches the network connection of drbd disks.
Static Method perspective_drbd_disconnect_net Disconnects the network connection of drbd disks.
Static Method perspective_drbd_helper Query drbd helper.
Static Method perspective_drbd_needs_activation Checks if the drbd devices need activation
Static Method perspective_drbd_wait_sync Wait until DRBD disks are synched.
Static Method perspective_etc_hosts_modify Modify a node entry in /etc/hosts.
Static Method perspective_export_info Query information about an existing export on this node.
Static Method perspective_export_list List the available exports on this node.
Static Method perspective_export_remove Remove an export.
Static Method perspective_export_start Starts an export daemon.
Static Method perspective_extstorage_diagnose Query detailed information about existing extstorage providers.
Static Method perspective_file_storage_dir_create Create the file storage directory.
Static Method perspective_file_storage_dir_remove Remove the file storage directory.
Static Method perspective_file_storage_dir_rename Rename the file storage directory.
Static Method perspective_finalize_export Expose the finalize export functionality.
Static Method perspective_get_file_info Get info on whether a file exists and its properties.
Static Method perspective_get_watcher_pause Get watcher pause end.
Static Method perspective_hooks_runner Run hook scripts.
Static Method perspective_hotplug_device Hotplugs device to a running instance.
Static Method perspective_hotplug_supported Checks if hotplug is supported.
Static Method perspective_hypervisor_validate_params Validate the hypervisor parameters.
Static Method perspective_iallocator_runner Run an iallocator script.
Static Method perspective_impexp_abort Aborts an import or export.
Static Method perspective_impexp_cleanup Cleans up after an import or export.
Static Method perspective_impexp_status Retrieves the status of an import or export daemon.
Static Method perspective_import_start Starts an import daemon.
Static Method perspective_instance_balloon_memory Modify instance runtime memory.
Static Method perspective_instance_console_info Query information on how to get console access to instances
Static Method perspective_instance_finalize_migration_dst Finalize the instance migration on the destination node.
Static Method perspective_instance_finalize_migration_src Finalize the instance migration on the source node.
Static Method perspective_instance_get_migration_status Reports migration status.
Static Method perspective_instance_info Query instance information.
Static Method perspective_instance_list Query the list of running instances.
Static Method perspective_instance_metadata_modify Modify instance metadata.
Static Method perspective_instance_migratable Query whether the specified instance can be migrated.
Static Method perspective_instance_migrate Migrates an instance.
Static Method perspective_instance_os_add Install an OS on a given instance.
Static Method perspective_instance_reboot Reboot an instance.
Static Method perspective_instance_run_rename Runs the OS rename script for an instance.
Static Method perspective_instance_shutdown Shutdown an instance.
Static Method perspective_instance_start Start an instance.
Static Method perspective_jobqueue_purge Purge job queue.
Static Method perspective_jobqueue_rename Rename a job queue file.
Static Method perspective_jobqueue_set_drain_flag Set job queue's drain flag.
Static Method perspective_jobqueue_update Update job queue.
Static Method perspective_lv_list Query the list of logical volumes in a given volume group.
Static Method perspective_master_node_name Returns the master node name.
Static Method perspective_migration_info Gather information about an instance to be migrated.
Static Method perspective_node_activate_master_ip Activate the master IP on this node.
Static Method perspective_node_change_master_netmask Change the master IP netmask.
Static Method perspective_node_configure_ovs Sets up OpenvSwitch on the node.
Static Method perspective_node_crypto_tokens Gets the node's public crypto tokens.
Static Method perspective_node_deactivate_master_ip Deactivate the master IP on this node.
Static Method perspective_node_demote_from_mc Demote a node from the master candidate role.
Static Method perspective_node_ensure_daemon Ensure daemon is running.
Static Method perspective_node_has_ip_address Checks if a node has the given ip address.
Static Method perspective_node_info Query node information.
Static Method perspective_node_leave_cluster Cleanup after leaving a cluster.
Static Method perspective_node_powercycle Tries to powercycle the node.
Static Method perspective_node_ssh_key_add Distributes a new node's SSH key if authorized.
Static Method perspective_node_ssh_key_remove Removes a node's SSH key from the other nodes' SSH files.
Static Method perspective_node_ssh_keys_renew Generates a new root SSH key pair on the node.
Static Method perspective_node_start_master_daemons Start the master daemons on this node.
Static Method perspective_node_stop_master Stops master daemons on this node.
Static Method perspective_node_verify Run a verify sequence on this node.
Static Method perspective_node_volumes Query the list of all logical volume groups.
Static Method perspective_os_diagnose Query detailed information about existing OSes.
Static Method perspective_os_export Export an OS definition into an instance specific package.
Static Method perspective_os_validate Run a given OS' validation routine.
Static Method perspective_restricted_command Runs a restricted command.
Static Method perspective_run_oob Runs oob on node.
Static Method perspective_set_watcher_pause Set watcher pause.
Static Method perspective_storage_execute Execute an operation on a storage unit.
Static Method perspective_storage_list Get list of storage units.
Static Method perspective_storage_modify Modify a storage unit.
Static Method perspective_test_delay Run test delay.
Static Method perspective_upload_file Upload a file.
Static Method perspective_upload_file_single Upload a file.
Static Method perspective_version Query version information.
Static Method perspective_vg_list Query the list of volume groups.
Static Method perspective_write_ssconf_files Write ssconf files.
Static Method perspective_x509_cert_create Creates a new X509 certificate for SSL/TLS.
Static Method perspective_x509_cert_remove Removes a X509 certificate.
Method __init__ Undocumented
Method HandleRequest Handle a request.
Instance Variable noded_pid Undocumented

Inherited from HttpServerHandler:

Static Method FormatErrorMessage Formats the body of an error message.
Method PreHandleRequest Called before handling a request.
@classmethod
def perspective_node_verify_light(cls, params):

Run a light verify sequence on this node.

This call is meant to perform a less strict verification of the node in certain situations. Right now, it is invoked only when a node is just about to be added to a cluster, and even then, it performs the same checks as perspective_node_verify.

@staticmethod
def perspective_accept_instance(params):

Prepare the node to accept an instance.

@staticmethod
def perspective_all_instances_info(params):

Query information about all instances.

@staticmethod
def perspective_bdev_sizes(params):

Query the list of block devices

@staticmethod
def perspective_blockdev_addchildren(params):

Add a child to a mirror device.

Note: this is only valid for mirror devices. It's the caller's duty to send a correct disk, otherwise we raise an error.

@staticmethod
def perspective_blockdev_assemble(params):

Assemble a block device.

@staticmethod
def perspective_blockdev_close(params):

Closes the given block devices.

@staticmethod
def perspective_blockdev_convert(params):

Copy data from source block device to target.

@staticmethod
def perspective_blockdev_create(params):

Create a block device.

@staticmethod
def perspective_blockdev_find(params):

Expose the FindBlockDevice functionality for a disk.

This will try to find but not activate a disk.

@staticmethod
def perspective_blockdev_getdimensions(params):

Compute the sizes of the given block devices.

@staticmethod
def perspective_blockdev_getmirrorstatus(params):

Return the mirror status for a list of disks.

@staticmethod
def perspective_blockdev_getmirrorstatus_multi(params):

Return the mirror status for a list of disks.

@staticmethod
def perspective_blockdev_grow(params):

Grow a stack of devices.

@staticmethod
def perspective_blockdev_image(params):

Image a block device.

@staticmethod
def perspective_blockdev_open(params):

Opens the given block devices.

@staticmethod
def perspective_blockdev_pause_resume_sync(params):

Pause/resume sync of a block device.

@staticmethod
def perspective_blockdev_remove(params):

Remove a block device.

@staticmethod
def perspective_blockdev_removechildren(params):

Remove a child from a mirror device.

This is only valid for mirror devices, of course. It's the callers duty to send a correct disk, otherwise we raise an error.

@staticmethod
def perspective_blockdev_rename(params):

Remove a block device.

@staticmethod
def perspective_blockdev_setinfo(params):

Sets metadata information on the given block device.

@staticmethod
def perspective_blockdev_shutdown(params):

Shutdown a block device.

@staticmethod
def perspective_blockdev_snapshot(params):

Create a snapshot device.

Note that this is only valid for LVM and ExtStorage disks, if we get passed something else we raise an exception. The snapshot device can be remove by calling the generic block device remove call.

@staticmethod
def perspective_blockdev_wipe(params):

Wipe a block device.

@staticmethod
def perspective_bridges_exist(params):

Check if all bridges given exist on this node.

@staticmethod
def perspective_drbd_attach_net(params):

Attaches the network connection of drbd disks.

Note that this is only valid for drbd disks, so the members of the disk list must all be drbd devices.

@staticmethod
def perspective_drbd_disconnect_net(params):

Disconnects the network connection of drbd disks.

Note that this is only valid for drbd disks, so the members of the disk list must all be drbd devices.

@staticmethod
def perspective_drbd_helper(_):

Query drbd helper.

@staticmethod
def perspective_drbd_needs_activation(params):

Checks if the drbd devices need activation

Note that this is only valid for drbd disks, so the members of the disk list must all be drbd devices.

@staticmethod
def perspective_drbd_wait_sync(params):

Wait until DRBD disks are synched.

Note that this is only valid for drbd disks, so the members of the disk list must all be drbd devices.

@staticmethod
def perspective_etc_hosts_modify(params):

Modify a node entry in /etc/hosts.

@staticmethod
def perspective_export_info(params):

Query information about an existing export on this node.

The given path may not contain an export, in which case we return None.

@staticmethod
def perspective_export_list(params):

List the available exports on this node.

Note that as opposed to export_info, which may query data about an export in any path, this only queries the standard Ganeti path (pathutils.EXPORT_DIR).

@staticmethod
def perspective_export_remove(params):

Remove an export.

@staticmethod
def perspective_export_start(params):

Starts an export daemon.

@staticmethod
def perspective_extstorage_diagnose(params):

Query detailed information about existing extstorage providers.

@staticmethod
def perspective_file_storage_dir_create(params):

Create the file storage directory.

@staticmethod
def perspective_file_storage_dir_remove(params):

Remove the file storage directory.

@staticmethod
def perspective_file_storage_dir_rename(params):

Rename the file storage directory.

@staticmethod
def perspective_finalize_export(params):

Expose the finalize export functionality.

@staticmethod
def perspective_get_file_info(params):

Get info on whether a file exists and its properties.

@staticmethod
def perspective_get_watcher_pause(params):

Get watcher pause end.

@staticmethod
def perspective_hooks_runner(params):

Run hook scripts.

@staticmethod
def perspective_hotplug_device(params):

Hotplugs device to a running instance.

@staticmethod
def perspective_hotplug_supported(params):

Checks if hotplug is supported.

@staticmethod
def perspective_hypervisor_validate_params(params):

Validate the hypervisor parameters.

@staticmethod
def perspective_iallocator_runner(params):

Run an iallocator script.

@staticmethod
def perspective_impexp_abort(params):

Aborts an import or export.

@staticmethod
def perspective_impexp_cleanup(params):

Cleans up after an import or export.

@staticmethod
def perspective_impexp_status(params):

Retrieves the status of an import or export daemon.

@staticmethod
def perspective_import_start(params):

Starts an import daemon.

@staticmethod
def perspective_instance_balloon_memory(params):

Modify instance runtime memory.

@staticmethod
def perspective_instance_console_info(params):

Query information on how to get console access to instances

@staticmethod
def perspective_instance_finalize_migration_dst(params):

Finalize the instance migration on the destination node.

@staticmethod
def perspective_instance_finalize_migration_src(params):

Finalize the instance migration on the source node.

@staticmethod
def perspective_instance_get_migration_status(params):

Reports migration status.

@staticmethod
def perspective_instance_info(params):

Query instance information.

@staticmethod
def perspective_instance_list(params):

Query the list of running instances.

@staticmethod
def perspective_instance_metadata_modify(params):

Modify instance metadata.

@staticmethod
def perspective_instance_migratable(params):

Query whether the specified instance can be migrated.

@staticmethod
def perspective_instance_migrate(params):

Migrates an instance.

@staticmethod
def perspective_instance_os_add(params):

Install an OS on a given instance.

@staticmethod
def perspective_instance_reboot(params):

Reboot an instance.

@staticmethod
def perspective_instance_run_rename(params):

Runs the OS rename script for an instance.

@staticmethod
def perspective_instance_shutdown(params):

Shutdown an instance.

@staticmethod
def perspective_instance_start(params):

Start an instance.

@staticmethod
@_RequireJobQueueLock
def perspective_jobqueue_purge(params):

Purge job queue.

@staticmethod
@_RequireJobQueueLock
def perspective_jobqueue_rename(params):

Rename a job queue file.

@staticmethod
@_RequireJobQueueLock
def perspective_jobqueue_set_drain_flag(params):

Set job queue's drain flag.

@staticmethod
@_RequireJobQueueLock
def perspective_jobqueue_update(params):

Update job queue.

@staticmethod
def perspective_lv_list(params):

Query the list of logical volumes in a given volume group.

@staticmethod
def perspective_master_node_name(params):

Returns the master node name.

@staticmethod
def perspective_migration_info(params):

Gather information about an instance to be migrated.

@staticmethod
def perspective_node_activate_master_ip(params):

Activate the master IP on this node.

@staticmethod
def perspective_node_change_master_netmask(params):

Change the master IP netmask.

@staticmethod
def perspective_node_configure_ovs(params):

Sets up OpenvSwitch on the node.

@staticmethod
def perspective_node_crypto_tokens(params):

Gets the node's public crypto tokens.

@staticmethod
def perspective_node_deactivate_master_ip(params):

Deactivate the master IP on this node.

@staticmethod
def perspective_node_demote_from_mc(params):

Demote a node from the master candidate role.

@staticmethod
def perspective_node_ensure_daemon(params):

Ensure daemon is running.

@staticmethod
def perspective_node_has_ip_address(params):

Checks if a node has the given ip address.

@staticmethod
def perspective_node_info(params):

Query node information.

@staticmethod
def perspective_node_leave_cluster(params):

Cleanup after leaving a cluster.

@staticmethod
def perspective_node_powercycle(params):

Tries to powercycle the node.

@staticmethod
def perspective_node_ssh_key_add(params):

Distributes a new node's SSH key if authorized.

@staticmethod
def perspective_node_ssh_key_remove(params):

Removes a node's SSH key from the other nodes' SSH files.

@staticmethod
def perspective_node_ssh_keys_renew(params):

Generates a new root SSH key pair on the node.

@staticmethod
def perspective_node_start_master_daemons(params):

Start the master daemons on this node.

@staticmethod
def perspective_node_stop_master(params):

Stops master daemons on this node.

@staticmethod
def perspective_node_verify(params):

Run a verify sequence on this node.

@staticmethod
def perspective_node_volumes(params):

Query the list of all logical volume groups.

@staticmethod
def perspective_os_diagnose(params):

Query detailed information about existing OSes.

@staticmethod
def perspective_os_export(params):

Export an OS definition into an instance specific package.

@staticmethod
def perspective_os_validate(params):

Run a given OS' validation routine.

@staticmethod
def perspective_restricted_command(params):

Runs a restricted command.

@staticmethod
def perspective_run_oob(params):

Runs oob on node.

@staticmethod
def perspective_set_watcher_pause(params):

Set watcher pause.

@staticmethod
def perspective_storage_execute(params):

Execute an operation on a storage unit.

@staticmethod
def perspective_storage_list(params):

Get list of storage units.

@staticmethod
def perspective_storage_modify(params):

Modify a storage unit.

@staticmethod
def perspective_test_delay(params):

Run test delay.

@staticmethod
def perspective_upload_file(params):

Upload a file.

Note that the backend implementation imposes strict rules on which files are accepted.

@staticmethod
def perspective_upload_file_single(params):

Upload a file.

Note that the backend implementation imposes strict rules on which files are accepted.

@staticmethod
def perspective_version(params):

Query version information.

@staticmethod
def perspective_vg_list(params):

Query the list of volume groups.

@staticmethod
def perspective_write_ssconf_files(params):

Write ssconf files.

@staticmethod
def perspective_x509_cert_create(params):

Creates a new X509 certificate for SSL/TLS.

@staticmethod
def perspective_x509_cert_remove(params):

Removes a X509 certificate.

def __init__(self):

Undocumented

def HandleRequest(self, req):
noded_pid =

Undocumented