Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
contego / home / tvault / .virtenv / lib / python2.7 / site-packages / nova / virt / driver.pyc
Size: Mime:
ó
±EYc@sdZddlZddlmZddlmZddlZddlZ	ddl
mZmZm
Z
ddl	mZddlmZe	jjZejeƒZd„Zd	„Zd
„Zd„Zd„Zd
„Zd„Zdefd„ƒYZe d„Z!d„Z"dS(s‰
Driver base-classes:

    (Beginning of) the contract that compute drivers must follow, and shared
    types that support that contract
iÿÿÿÿN(tlog(timportutils(t_t_LEt_LI(tutils(teventc	OsXtƒ}xH|D]@}|jdƒ\}}}tj|ƒ}|||Ž||<qW|S(Nt=(tdictt	partitionRtimport_class(	tnamed_driver_configtargstkwargstdriver_registryt
driver_strtdriver_typet_septdrivertdriver_class((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytdriver_dict_from_config&s	
cCsfddlm}i|jd6|j|ƒd6|j|Œd6}|j|ƒ}|j|ƒ|d<|S(sJConverts block device mappings for an instance to driver format.

    Virt drivers expect block device mapping to be presented in the format
    of a dict containing the following keys:

    - root_device_name: device name of the root disk
    - ephemerals: a (potentially empty) list of DriverEphemeralBlockDevice
                  instances
    - swap: An instance of DriverSwapBlockDevice or None
    - block_device_mapping: a (potentially empty) list of
                            DriverVolumeBlockDevice or any of it's more
                            specialized subclasses.
    iÿÿÿÿ(tblock_devicetroot_device_namet
ephemeralstblock_device_mappingtswap(t	nova.virtRRtconvert_ephemeralstconvert_all_volumestconvert_swaptget_swap(tinstanceRtvirt_block_devicetblock_device_infot	swap_list((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_block_device_info1s

cCs|p	i}|jdƒS(NR(tget(R!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytblock_device_info_get_rootNscCs-|p	i}|jdƒp,idd6dd6S(NRtdevice_nameit	swap_size(R$tNone(R!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytblock_device_info_get_swapSscCs|o|do|ddkS(NR&R'i((R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytswap_is_usableYscCs%|p	i}|jdƒpg}|S(NR(R$(R!R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt block_device_info_get_ephemerals]scCs%|p	i}|jdƒpg}|S(NR(R$(R!R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytblock_device_info_get_mappingcst
ComputeDrivercBs¨eZdZied6ed6ed6ed6ed6Zd„Zd„Zd„Zd	„Zd
„Z	d„Z
d„Zd
„Zd„Z
dvedved„Zdvdvd„Zdvedvd„Zdvedved„Zdvdvd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Z dvdvdvd „Z!dvd!„Z"d"„Z#d#„Z$d$„Z%dvd%d%d&„Z&d'„Z'd(„Z(dved)„Z)d*„Z*dved+„Z+d,„Z,d-„Z-d.„Z.dvd/„Z/dvd0„Z0d1„Z1d2„Z2d3„Z3d%d%d4„Z4dvd5„Z5d6„Z6d7„Z7d8„Z8d9„Z9d:„Z:edvd;„Z;d<„Z<d=„Z=edvd>„Z>dvd?„Z?d@„Z@edvdA„ZAdB„ZBdC„ZCdD„ZDeedE„ZEdF„ZFdvdG„ZGdvdH„ZHdI„ZIdJ„ZJdK„ZKdL„ZLdM„ZMdN„ZNdO„ZOdP„ZPdQ„ZQdR„ZRdS„ZSdT„ZTdU„ZUdV„ZVdW„ZWdX„ZXdY„ZYdZ„ZZd[„Z[d\„Z\d]„Z]d^„Z^d_„Z_d`„Z`da„Zadb„Zbedc„Zcdd„Zdede„Zedf„Zfdg„Zgdh„Zhdi„Zidj„Zjdk„Zkeldl„ƒZmdm„Zndn„Zodo„Zpdp„Zqdq„Zrdr„Zsds„Ztdt„Zudu„ZvRS(wsØBase class for compute drivers.

    The interface to this class talks in terms of 'instances' (Amazon EC2 and
    internal Nova terminology), by which we mean 'running virtual machine'
    (XenAPI terminology) or domain (Xen or libvirt terminology).

    An instance has an ID, which is the identifier chosen by Nova to represent
    the instance further up the stack.  This is unfortunately also called a
    'name' elsewhere.  As far as this layer is concerned, 'instance ID' and
    'instance name' are synonyms.

    Note that the instance ID or name is not human-readable or
    customer-controlled -- it's an internal ID chosen by Nova.  At the
    nova.virt layer, instances do not have human-readable names at all -- such
    things are only known higher up the stack.

    Most virtualization platforms will also have their own identity schemes,
    to uniquely identify a VM or domain.  These IDs must stay internal to the
    platform-specific layer, and never escape the connection interface.  The
    platform-specific layer is responsible for keeping track of which instance
    ID maps to which platform-specific ID, and vice versa.

    Some methods here take an instance of nova.compute.service.Instance.  This
    is the data structure used by nova.compute to store details regarding an
    instance, and pass them into this layer.  This layer is responsible for
    translating that generic data structure into terms that are specific to the
    virtualization platform.

    thas_imagecachetsupports_recreatetsupports_migrate_to_same_hosttsupports_attach_interfacetsupports_device_taggingcCs||_d|_dS(N(tvirtapiR(t_compute_event_callback(tselfR3((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt__init__s	cCs
tƒ‚dS(s—Initialize anything that is necessary for the driver to function,
        including catching up with currently running VM's on the given host.
        N(tNotImplementedError(R5thost((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt	init_host”scCsdS(sˆClean up anything that is necessary for the driver gracefully stop,
        including ending remote sessions. This is optional.
        N((R5R8((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytcleanup_host›scCs
tƒ‚dS(s¨Get the current status of an instance, by name (not ID!)

        :param instance: nova.objects.instance.Instance object

        Returns a InstanceInfo object
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_info¡scCst|jƒƒS(sˆReturn the total number of virtual machines.

        Return the number of virtual machines that the hypervisor knows
        about.

        .. note::

            This implementation works for all drivers, but it is
            not particularly efficient. Maintainers of the virt drivers are
            encouraged to override this method with something more
            efficient.
        (tlentlist_instances(R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_num_instances«s
cCs?y|j|jƒkSWn!tk
r:|j|jƒkSXdS(sÈChecks existence of an instance on the host.

        :param instance: The instance to lookup

        Returns True if an instance with the supplied ID exists on
        the host, False otherwise.

        .. note::

            This implementation works for all drivers, but it is
            not particularly efficient. Maintainers of the virt drivers are
            encouraged to override this method with something more
            efficient.
        N(tuuidtlist_instance_uuidsR7tnameR=(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytinstance_existsºs
cCsidd6dd6S(sUEstimate the virtualization overhead required to build an instance
        of the given flavor.

        Defaults to zero, drivers should override if per-instance overhead
        calculations are desired.

        :param instance_info: Instance/flavor to calculate overhead for.
        :returns: Dict of estimated overhead values.
        it	memory_mbtdisk_gb((R5t
instance_info((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytestimate_instance_overheadÎs

cCs
tƒ‚dS(sdReturn the names of all the instances known to the virtualization
        layer, as a list.
        N(R7(R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyR=ÛscCs
tƒ‚dS(sdReturn the UUIDS of all the instances known to the virtualization
        layer, as a list.
        N(R7(R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyR@âsc

Cs
tƒ‚dS(sADestroy and re-make this instance.

        A 'rebuild' effectively purges all existing data from the system and
        remakes the VM with given 'metadata' and 'personalities'.

        This base class method shuts down the VM, detaches all block devices,
        then spins up the new VM afterwards. It may be overridden by
        hypervisors that need to - e.g. for optimisations, or when the 'VM'
        is actually proxied and needs to be held across the shutdown + spin
        up steps.

        :param context: security context
        :param instance: nova.objects.instance.Instance
                         This function should use the data there to guide
                         the creation of the new instance.
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        :param injected_files: User files to inject into instance.
        :param admin_password: Administrator password to set in instance.
        :param bdms: block-device-mappings to use for rebuild
        :param detach_block_devices: function to detach block devices. See
            nova.compute.manager.ComputeManager:_rebuild_default_impl for
            usage.
        :param attach_block_devices: function to attach block devices. See
            nova.compute.manager.ComputeManager:_rebuild_default_impl for
            usage.
        :param network_info: instance network information
        :param recreate: True if the instance is being recreated on a new
            hypervisor - all the cleanup of old state is skipped.
        :param block_device_info: Information about block devices to be
                                  attached to the instance.
        :param preserve_ephemeral: True if the default ephemeral storage
                                   partition must be preserved on rebuild
        N(R7(
R5tcontextRt
image_metatinjected_filestadmin_passwordtbdmstdetach_block_devicestattach_block_devicestnetwork_infotrecreateR!tpreserve_ephemeral((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytrebuildès'cCs
tƒ‚dS(sCreate a new instance/VM/domain on the virtualization platform.

        Once this successfully completes, the instance should be
        running (power_state.RUNNING).

        If this fails, any partial instance should be completely
        cleaned up, and the virtualization platform should be in the state
        that it was before this call began.

        :param context: security context
        :param instance: nova.objects.instance.Instance
                         This function should use the data there to guide
                         the creation of the new instance.
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        :param injected_files: User files to inject into instance.
        :param admin_password: Administrator password to set in instance.
        :param network_info: instance network information
        :param block_device_info: Information about block devices to be
                                  attached to the instance.
        N(R7(R5RGRRHRIRJRNR!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytspawnscCs
tƒ‚dS(sªDestroy the specified instance from the Hypervisor.

        If the instance is not found (for example if networking failed), this
        function should still succeed.  It's probably a good idea to log a
        warning in that case.

        :param context: security context
        :param instance: Instance object as returned by DB layer.
        :param network_info: instance network information
        :param block_device_info: Information about block devices that should
                                  be detached from the instance.
        :param destroy_disks: Indicates if disks should be destroyed
        :param migrate_data: implementation specific params
        N(R7(R5RGRRNR!t
destroy_diskstmigrate_data((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytdestroy*scCs
tƒ‚dS(sDCleanup the instance resources .

        Instance should have been destroyed from the Hypervisor before calling
        this method.

        :param context: security context
        :param instance: Instance object as returned by DB layer.
        :param network_info: instance network information
        :param block_device_info: Information about block devices that should
                                  be detached from the instance.
        :param destroy_disks: Indicates if disks should be destroyed
        :param migrate_data: implementation specific params
        N(R7(R5RGRRNR!RSRTtdestroy_vifs((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytcleanup<scCs
tƒ‚dS(s¥Reboot the specified instance.

        After this is called successfully, the instance's state
        goes back to power_state.RUNNING. The virtualization
        platform should ensure that the reboot action has completed
        successfully even in cases in which the underlying domain/vm
        is paused or halted/stopped.

        :param instance: nova.objects.instance.Instance
        :param network_info: instance network information
        :param reboot_type: Either a HARD or SOFT reboot
        :param block_device_info: Info pertaining to attached volumes
        :param bad_volumes_callback: Function to handle any bad volumes
            encountered
        N(R7(R5RGRRNtreboot_typeR!tbad_volumes_callback((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytrebootMscCs
tƒ‚dS(N(R7(R5tconsole_type((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_console_pool_info`scCs
tƒ‚dS(sGet console output for an instance

        :param context: security context
        :param instance: nova.objects.instance.Instance
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_console_outputdscCs
tƒ‚dS(sÊGet connection info for a vnc console.

        :param context: security context
        :param instance: nova.objects.instance.Instance

        :returns an instance of console.type.ConsoleVNC
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_vnc_consolelscCs
tƒ‚dS(sÎGet connection info for a spice console.

        :param context: security context
        :param instance: nova.objects.instance.Instance

        :returns an instance of console.type.ConsoleSpice
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_spice_consolevscCs
tƒ‚dS(sÊGet connection info for a rdp console.

        :param context: security context
        :param instance: nova.objects.instance.Instance

        :returns an instance of console.type.ConsoleRDP
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_rdp_console€scCs
tƒ‚dS(sÐGet connection info for a serial console.

        :param context: security context
        :param instance: nova.objects.instance.Instance

        :returns an instance of console.type.ConsoleSerial
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_serial_consoleŠscCs
tƒ‚dS(sÊGet connection info for a MKS console.

        :param context: security context
        :param instance: nova.objects.instance.Instance

        :returns an instance of console.type.ConsoleMKS
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_mks_console”scCs
tƒ‚dS(sNReturn diagnostics data about the given instance.

        :param nova.objects.instance.Instance instance:
            The instance to which the diagnostic data should be returned.

        :return: Has a big overlap to the return value of the newer interface
            :func:`get_instance_diagnostics`
        :rtype: dict
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_diagnosticsžscCs
tƒ‚dS(sbReturn diagnostics data about the given instance.

        :param nova.objects.instance.Instance instance:
            The instance to which the diagnostic data should be returned.

        :return: Has a big overlap to the return value of the older interface
            :func:`get_diagnostics`
        :rtype: nova.virt.diagnostics.Diagnostics
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_instance_diagnostics«s
cCs
tƒ‚dS(s˜Return bandwidth usage counters for each interface on each
           running VM.

        :param instances: nova.objects.instance.InstanceList
        N(R7(R5t	instances((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_all_bw_counters·scCs
tƒ‚dS(sSReturn usage info for volumes attached to vms on
           a given host.-
        N(R7(R5RGtcompute_host_bdms((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_all_volume_usage¿scCs
tƒ‚dS(s-Retrieves the IP address of the dom0
        N(R7(R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_host_ip_addrÅscCs
tƒ‚dS(s9Attach the disk to the instance at mountpoint using info.N(R7(R5RGtconnection_infoRt
mountpointtdisk_bustdevice_typet
encryption((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt
attach_volumeËscCs
tƒ‚dS(s)Detach the disk attached to the instance.N(R7(R5RjRRkRn((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt
detach_volumeÐscCs
tƒ‚dS(sReplace the volume attached to the given `instance`.

        :param dict old_connection_info:
            The volume for this connection gets detached from the given
            `instance`.
        :param dict new_connection_info:
            The volume for this connection gets attached to the given
            'instance'.
        :param nova.objects.instance.Instance instance:
            The instance whose volume gets replaced by another one.
        :param str mountpoint:
            The mountpoint in the instance where the volume for
            `old_connection_info` is attached to.
        :param int resize_to:
            If the new volume is larger than the old volume, it gets resized
            to the given size (in Gigabyte) of `resize_to`.

        :return: None
        N(R7(R5told_connection_infotnew_connection_infoRRkt	resize_to((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytswap_volumeÕscCs
tƒ‚dS(sOUse hotplug to add a network interface to a running instance.

        The counter action to this is :func:`detach_interface`.

        :param nova.objects.instance.Instance instance:
            The instance which will get an additional network interface.
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        :param nova.network.model.NetworkInfo vif:
            The object which has the information about the interface to attach.

        :raise nova.exception.NovaException: If the attach fails.

        :return: None
        N(R7(R5RRHtvif((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytattach_interfaceìscCs
tƒ‚dS(såUse hotunplug to remove a network interface from a running instance.

        The counter action to this is :func:`attach_interface`.

        :param nova.objects.instance.Instance instance:
            The instance which gets a network interface removed.
        :param nova.network.model.NetworkInfo vif:
            The object which has the information about the interface to detach.

        :raise nova.exception.NovaException: If the detach fails.

        :return: None
        N(R7(R5RRu((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytdetach_interfaceþsic		Cs
tƒ‚dS(s›Transfers the disk of a running instance in multiple phases, turning
        off the instance before the end.

        :param nova.objects.instance.Instance instance:
            The instance whose disk should be migrated.
        :param str dest:
            The IP address of the destination host.
        :param nova.objects.flavor.Flavor flavor:
            The flavor of the instance whose disk get migrated.
        :param nova.network.model.NetworkInfo network_info:
            The network information of the given `instance`.
        :param dict block_device_info:
            Information about the block devices.
        :param int timeout:
            The time in seconds to wait for the guest OS to shutdown.
        :param int retry_interval:
            How often to signal guest while waiting for it to shutdown.

        :return: A list of disk information dicts in JSON format.
        :rtype: str
        N(R7(	R5RGRtdesttflavorRNR!ttimeouttretry_interval((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytmigrate_disk_and_power_offscCs
tƒ‚dS(süSnapshots the specified instance.

        :param context: security context
        :param instance: nova.objects.instance.Instance
        :param image_id: Reference to a pre-created image that will
                         hold the snapshot.
        N(R7(R5RGRtimage_idtupdate_task_state((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytsnapshot)scCsdS(s¦Cleans up any resources left after an interrupted snapshot.

        :param context: security context
        :param instance: nova.objects.instance.Instance
        N((R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt!post_interrupted_snapshot_cleanup3sc

Cs
tƒ‚dS(søCompletes a resize/migration.

        :param context: the context for the migration/resize
        :param migration: the migrate/resize information
        :param instance: nova.objects.instance.Instance being migrated/resized
        :param disk_info: the newly transferred disk information
        :param network_info: instance network information
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        :param resize_instance: True if the instance is being resized,
                                False otherwise
        :param block_device_info: instance volume block device info
        :param power_on: True if the instance should be powered on, False
                         otherwise
        N(R7(
R5RGt	migrationRt	disk_infoRNRHtresize_instanceR!tpower_on((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytfinish_migration;scCs
tƒ‚dS(sxConfirms a resize/migration, destroying the source VM.

        :param instance: nova.objects.instance.Instance
        N(R7(R5RRRN((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytconfirm_migrationOscCs
tƒ‚dS(s¬Finish reverting a resize/migration.

        :param context: the context for the finish_revert_migration
        :param instance: nova.objects.instance.Instance being migrated/resized
        :param network_info: instance network information
        :param block_device_info: instance volume block device info
        :param power_on: True if the instance should be powered on, False
                         otherwise
        N(R7(R5RGRRNR!R„((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytfinish_revert_migrationWscCs
tƒ‚dS(sôPause the given instance.

        A paused instance doesn't use CPU cycles of the host anymore. The
        state of the VM could be stored in the memory or storage space of the
        host, depending on the underlying hypervisor technology.
        A "stronger" version of `pause` is :func:'suspend'.
        The counter action for `pause` is :func:`unpause`.

        :param nova.objects.instance.Instance instance:
            The instance which should be paused.

        :return: None
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytpausedscCs
tƒ‚dS(s¶Unpause the given paused instance.

        The paused instance gets unpaused and will use CPU cycles of the
        host again. The counter action for 'unpause' is :func:`pause`.
        Depending on the underlying hypervisor technology, the guest has the
        same state as before the 'pause'.

        :param nova.objects.instance.Instance instance:
            The instance which should be unpaused.

        :return: None
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytunpauseuscCs
tƒ‚dS(s&Suspend the specified instance.

        A suspended instance doesn't use CPU cycles or memory of the host
        anymore. The state of the instance could be persisted on the host
        and allocate storage space this way. A "softer" way of `suspend`
        is :func:`pause`. The counter action for `suspend` is :func:`resume`.

        :param nova.context.RequestContext context:
            The context for the suspend.
        :param nova.objects.instance.Instance instance:
            The instance to suspend.

        :return: None
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytsuspend…scCs
tƒ‚dS(sïresume the specified suspended instance.

        The suspended instance gets resumed and will use CPU cycles and memory
        of the host again. The counter action for 'resume' is :func:`suspend`.
        Depending on the underlying hypervisor technology, the guest has the
        same state as before the 'suspend'.

        :param nova.context.RequestContext context:
            The context for the resume.
        :param nova.objects.instance.Instance instance:
            The suspended instance to resume.
        :param nova.network.model.NetworkInfo network_info:
            Necessary network information for the resume.
        :param dict block_device_info:
            Instance volume block device info.

        :return: None
        N(R7(R5RGRRNR!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytresume–scCs
tƒ‚dS(skresume guest state when a host is booted.

        :param instance: nova.objects.instance.Instance
        N(R7(R5RGRRNR!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytresume_state_on_host_boot«scCs
tƒ‚dS(sRescue the specified instance.

        :param nova.context.RequestContext context:
            The context for the rescue.
        :param nova.objects.instance.Instance instance:
            The instance being rescued.
        :param nova.network.model.NetworkInfo network_info:
            Necessary network information for the resume.
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        :param rescue_password: new root password to set for rescue.
        N(R7(R5RGRRNRHtrescue_password((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytrescue³scCs
tƒ‚dS(snSet the ability to power on/off an instance.

        :param instance: nova.objects.instance.Instance
        N(R7(R5Rtis_bootable((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytset_bootableÃscCs
tƒ‚dS(sbUnrescue the specified instance.

        :param instance: nova.objects.instance.Instance
        N(R7(R5RRN((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytunrescueÊscCs
tƒ‚dS(sPower off the specified instance.

        :param instance: nova.objects.instance.Instance
        :param timeout: time to wait for GuestOS to shutdown
        :param retry_interval: How often to signal guest while
                               waiting for it to shutdown
        N(R7(R5RRzR{((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt	power_offÒscCs
tƒ‚dS(sbPower on the specified instance.

        :param instance: nova.objects.instance.Instance
        N(R7(R5RGRRNR!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyR„ÜscCs
tƒ‚dS(sdTrigger crash dump mechanism on the given instance.

        Stalling instances can be triggered to dump the crash data. How the
        guest OS reacts in details, depends on the configuration of it.

        :param nova.objects.instance.Instance instance:
            The instance where the crash dump should be triggered.

        :return: None
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyttrigger_crash_dumpäscCs
tƒ‚dS(sSoft delete the specified instance.

        A soft-deleted instance doesn't allocate any resources anymore, but is
        still available as a database entry. The counter action :func:`restore`
        uses the database entry to create a new instance based on that.

        :param nova.objects.instance.Instance instance:
            The instance to soft-delete.

        :return: None
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytsoft_deleteñscCs
tƒ‚dS(sjRestore the specified soft-deleted instance.

        The restored instance will be automatically booted. The counter action
        for `restore` is :func:`soft_delete`.

        :param nova.objects.instance.Instance instance:
            The soft-deleted instance which should be restored from the
            soft-deleted data.

        :return: None
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytrestoreÿscCs
tƒ‚dS(s}Retrieve resource information.

        This method is called when nova-compute launches, and
        as part of a periodic task that records the results in the DB.

        :param nodename:
            node which the caller want to get resources from
            a driver that manages only one node can safely ignore this
        :returns: Dictionary describing resources
        N(R7(R5tnodename((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_available_resource
scCs
tƒ‚dS(s€Prepare an instance for live migration

        :param context: security context
        :param instance: nova.objects.instance.Instance object
        :param block_device_info: instance block device information
        :param network_info: instance network information
        :param disk_info: instance disk information
        :param migrate_data: a LiveMigrateData object
        N(R7(R5RGRR!RNR‚RT((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytpre_live_migrationscCs
tƒ‚dS(sŽLive migration of an instance to another host.

        :param context: security context
        :param instance:
            nova.db.sqlalchemy.models.Instance object
            instance object that is migrated.
        :param dest: destination host
        :param post_method:
            post operation method.
            expected nova.compute.manager._post_live_migration.
        :param recover_method:
            recovery method when any exception occurs.
            expected nova.compute.manager._rollback_live_migration.
        :param block_migration: if true, migrate VM disk.
        :param migrate_data: a LiveMigrateData object

        N(R7(R5RGRRxtpost_methodtrecover_methodtblock_migrationRT((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytlive_migration'scCs
tƒ‚dS(saForce live migration to complete

        :param instance: Instance being live migrated

        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytlive_migration_force_complete=scCs
tƒ‚dS(shAbort an in-progress live migration.

        :param instance: instance that is live migrating

        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytlive_migration_abortEscCs
tƒ‚dS(sÀClean up destination node after a failed live migration.

        :param context: security context
        :param instance: instance object that was being migrated
        :param network_info: instance network information
        :param block_device_info: instance block device information
        :param destroy_disks:
            if true, destroy disks at destination during cleanup
        :param migrate_data: a LiveMigrateData object

        N(R7(R5RGRRNR!RSRT((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt&rollback_live_migration_at_destinationMscCsdS(sPost operation of live migration at source host.

        :param context: security context
        :instance: instance object that was migrated
        :block_device_info: instance block device information
        :param migrate_data: a LiveMigrateData object
        N((R5RGRR!RT((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytpost_live_migration_s	cCsttdƒƒ‚dS(sÄUnplug VIFs from networks at source.

        :param context: security context
        :param instance: instance object reference
        :param network_info: instance network information
        sGHypervisor driver does not support post_live_migration_at_source methodN(R7R(R5RGRRN((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytpost_live_migration_at_sourcejscCs
tƒ‚dS(s(Post operation of live migration at destination host.

        :param context: security context
        :param instance: instance object that is migrated
        :param network_info: instance network information
        :param block_migration: if true, post operation of block_migration.
        N(R7(R5RGRRNR›R!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt"post_live_migration_at_destinationtscCs
tƒ‚dS(sCheck if instance files located on shared storage.

        This runs check on the destination host, and then calls
        back to the source host to check the results.

        :param context: security context
        :param instance: nova.objects.instance.Instance object
        N(R7(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt#check_instance_shared_storage_locals	cCs
tƒ‚dS(s¨Check if instance files located on shared storage.

        :param context: security context
        :param data: result of check_instance_shared_storage_local
        N(R7(R5RGtdata((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt$check_instance_shared_storage_remoteŒscCsdS(s²Do cleanup on host after check_instance_shared_storage calls

        :param context: security context
        :param data: result of check_instance_shared_storage_local
        N((R5RGR¤((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt%check_instance_shared_storage_cleanup”scCs
tƒ‚dS(scCheck if it is possible to execute live migration.

        This runs checks on the destination host, and then calls
        back to the source host to check the results.

        :param context: security context
        :param instance: nova.db.sqlalchemy.models.Instance
        :param src_compute_info: Info about the sending machine
        :param dst_compute_info: Info about the receiving machine
        :param block_migration: if true, prepare for block migration
        :param disk_over_commit: if true, allow disk over commit
        :returns: a LiveMigrateData object (hypervisor-dependent)
        N(R7(R5RGRtsrc_compute_infotdst_compute_infoR›tdisk_over_commit((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt"check_can_live_migrate_destinationœscCs
tƒ‚dS(sÃDo required cleanup on dest host after check_can_live_migrate calls

        :param context: security context
        :param dest_check_data: result of check_can_live_migrate_destination
        N(R7(R5RGtdest_check_data((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt(cleanup_live_migration_destination_check¯scCs
tƒ‚dS(sãCheck if it is possible to execute live migration.

        This checks if the live migration can succeed, based on the
        results from check_can_live_migrate_destination.

        :param context: security context
        :param instance: nova.db.sqlalchemy.models.Instance
        :param dest_check_data: result of check_can_live_migrate_destination
        :param block_device_info: result of _get_instance_block_device_info
        :returns: a LiveMigrateData object
        N(R7(R5RGRR«R!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytcheck_can_live_migrate_source¸s
cCs
tƒ‚dS(s_Retrieve information about actual disk sizes of an instance.

        :param instance: nova.objects.Instance
        :param block_device_info:
            Optional; Can be used to filter out devices which are
            actually volumes.
        :return:
            json strings with below format::

                "[{'path':'disk',
                   'type':'raw',
                   'virt_disk_size':'10737418240',
                   'backing_file':'backing_file',
                   'disk_size':'83886080'
                   'over_committed_disk_size':'10737418240'},
                   ...]"
        N(R7(R5RR!((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_instance_disk_infoÇscCs
tƒ‚dS(sPThis method is called after a change to security groups.

        All security groups and their associated rules live in the datastore,
        and calling this method should apply the updated rules to instances
        running the specified security group.

        An error should be raised if the operation cannot complete.

        N(R7(R5tsecurity_group_id((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytrefresh_security_group_rulesÜscCs
tƒ‚dS(sÏRefresh security group rules

        Gets called when an instance gets added to or removed from
        the security group the instance is a member of or if the
        group gains or loses a rule.
        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytrefresh_instance_security_ruleséscCsdS(s(reset networking for specified instance.N((R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt
reset_networkòscCs
tƒ‚dS(s}Setting up filtering rules and waiting for its completion.

        To migrate an instance, filtering rules to hypervisors
        and firewalls are inevitable on destination host.
        ( Waiting only for filtering rules to hypervisor,
        since filtering rules to firewall rules can be set faster).

        Concretely, the below method must be called.
        - setup_basic_filtering (for nova-basic, etc.)
        - prepare_instance_filter(for nova-instance-instance-xxx, etc.)

        to_xml may have to be called since it defines PROJNET, PROJMASK.
        but libvirt migrates those value through migrateToURI(),
        so , no need to be called.

        Don't use thread for this method since migration should
        not be started when setting-up filtering rules operations
        are not completed.

        :param instance: nova.objects.instance.Instance object

        N(R7(R5RRN((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt#ensure_filtering_rules_for_instance÷scCsdS(s$Defer application of IPTables rules.N((R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytfilter_defer_apply_onscCsdS(s<Turn off deferral of IPTables rules and apply the rules now.N((R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytfilter_defer_apply_offscCs
tƒ‚dS(sStop filtering instance.N(R7(R5RRN((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytunfilter_instancescCs
tƒ‚dS(sœSet the root password on the specified instance.

        :param instance: nova.objects.instance.Instance
        :param new_pass: the new password
        N(R7(R5Rtnew_pass((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytset_admin_passwordscCs
tƒ‚dS(søWrites a file on the specified instance.

        The first parameter is an instance of nova.compute.service.Instance,
        and so the instance is being specified as instance.name. The second
        parameter is the base64-encoded path to which the file is to be
        written on the instance; the third is the contents of the file, also
        base64-encoded.

        NOTE(russellb) This method is deprecated and will be removed once it
        can be removed from nova.compute.manager.
        N(R7(R5Rtb64_pathtb64_contents((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytinject_file&s
cCsdS(s¦Applies a diff to the instance metadata.

        This is an optional driver method which is used to publish
        changes to the instance's metadata to the hypervisor.  If the
        hypervisor has no means of publishing the instance metadata to
        the instance, then this method should not be implemented.

        :param context: security context
        :param instance: nova.objects.instance.Instance
        N((R5RGRtdiff((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytchange_instance_metadata5scCsdS(s+inject network info for specified instance.N((R5Rtnw_info((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytinject_network_infoBscCs
tƒ‚dS(sæPerform a reboot on all given 'instances'.

        Reboots the given `instances` which are longer in the rebooting state
        than `timeout` seconds.

        :param int timeout:
            The timeout (in seconds) for considering rebooting instances
            to be stuck.
        :param list instances:
            A list of nova.objects.instance.Instance objects that have been
            in rebooting state longer than the configured timeout.

        :return: None
        N(R7(R5RzRe((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytpoll_rebooting_instancesGscCs
tƒ‚dS(sReboots, shuts down or powers up the host.

        :param str action:
            The action the host should perform. The valid actions are:
            ""startup", "shutdown" and "reboot".

        :return: The result of the power action
        :rtype: : str
        N(R7(R5taction((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pythost_power_actionYscCs
tƒ‚dS(s9Start/Stop host maintenance window.

        On start, it triggers the migration of all instances to other hosts.
        Consider the combination with :func:`set_host_enabled`.

        :param str host:
            The name of the host whose maintenance mode should be changed.
        :param bool mode:
            If `True`, go into maintenance mode. If `False`, leave the
            maintenance mode.

        :return: "on_maintenance" if switched to maintenance mode or
                 "off_maintenance" if maintenance mode got left.
        :rtype: str
        N(R7(R5R8tmode((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pythost_maintenance_modefscCs
tƒ‚dS(s´Sets the ability of this host to accept new instances.

        :param bool enabled:
            If this is `True`, the host will accept new instances. If it is
            `False`, the host won't accept new instances.

        :return: If the host can accept further instances, return "enabled",
                 if further instances shouldn't be scheduled to this host,
                 return "disabled".
        :rtype: str
        N(R7(R5tenabled((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytset_host_enabledys
cCs
tƒ‚dS(sÑReturns the result of calling the Linux command `uptime` on this
        host.

        :return: A text which contains the uptime of this host since the
                 last boot.
        :rtype: str
        N(R7(R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_host_uptimeˆs	cCs
tƒ‚dS(sœPlug virtual interfaces (VIFs) into the given `instance` at
        instance boot time.

        The counter action is :func:`unplug_vifs`.

        :param nova.objects.instance.Instance instance:
            The instance which gets VIFs plugged.
        :param nova.network.model.NetworkInfo network_info:
            The object which contains information about the VIFs to plug.

        :return: None
        N(R7(R5RRN((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt	plug_vifs“scCs
tƒ‚dS(svUnplug virtual interfaces (VIFs) from networks.

        The counter action is :func:`plug_vifs`.

        :param nova.objects.instance.Instance instance:
            The instance which gets VIFs unplugged.
        :param nova.network.model.NetworkInfo network_info:
            The object which contains information about the VIFs to unplug.

        :return: None
        N(R7(R5RRN((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytunplug_vifs£scCs
tƒ‚dS(sãGet the currently known host CPU stats.

        :returns: a dict containing the CPU stat info, eg:

            | {'kernel': kern,
            |  'idle': idle,
            |  'user': user,
            |  'iowait': wait,
            |   'frequency': freq},

                  where kern and user indicate the cumulative CPU time
                  (nanoseconds) spent by kernel and user processes
                  respectively, idle indicates the cumulative idle CPU time
                  (nanoseconds), wait indicates the cumulative I/O wait CPU
                  time (nanoseconds), since the host is booting up; freq
                  indicates the current CPU frequency (MHz). All values are
                  long integers.

        N(R7(R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_host_cpu_stats´scCs
tƒ‚dS(sìReturn performance counters associated with the given disk_id on the
        given instance.  These are returned as [rd_req, rd_bytes, wr_req,
        wr_bytes, errs], where rd indicates read, wr indicates write, req is
        the total number of I/O requests made, bytes is the total number of
        bytes transferred, and errs is the number of requests held up due to a
        full pipeline.

        All counters are long integers.

        This method is optional.  On some platforms (e.g. XenAPI) performance
        statistics can be retrieved directly in aggregate form, without Nova
        having to do the aggregation.  On those platforms, this method is
        unused.

        Note that this function takes an instance ID.
        N(R7(R5Rtdisk_id((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytblock_statsÊscCstS(s8Does the driver want networks deallocated on reschedule?(tFalse(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt!deallocate_networks_on_rescheduleÝscCsdS(s}What MAC addresses must this instance have?

        Some hypervisors (such as bare metal) cannot do freeform virtualization
        of MAC addresses. This method allows drivers to return a set of MAC
        addresses that the instance is to have. allocate_for_instance will take
        this into consideration when provisioning networking for the instance.

        Mapping of MAC addresses to actual networks (or permitting them to be
        freeform) is up to the network implementation layer. For instance,
        with openflow switches, fixed MAC addresses can still be virtualized
        onto any L2 domain, with arbitrary VLANs etc, but regular switches
        require pre-configured MAC->network mappings that will match the
        actual configuration.

        Most hypervisors can use the default implementation which returns None.
        Hypervisors with MAC limits should return a set of MAC addresses, which
        will be supplied to the allocate_for_instance call by the compute
        manager, and it is up to that call to ensure that all assigned network
        details are compatible with the set of MAC addresses.

        This is called during spawn_instance by the compute manager.

        :return: None, or a set of MAC ids (e.g. set(['12:34:56:78:90:ab'])).
            None means 'no constraints', a set means 'these and only these
            MAC addresses'.
        N(R((R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytmacs_for_instanceáscCsdS(srGet DHCP options for this instance.

        Some hypervisors (such as bare metal) require that instances boot from
        the network, and manage their own TFTP service. This requires passing
        the appropriate options out to the DHCP service. Most hypervisors can
        use the default implementation which returns None.

        This is called during spawn_instance by the compute manager.

        Note that the format of the return value is specific to the Neutron
        client API.

        :return: None, or a set of DHCP options, eg:

             |    [{'opt_name': 'bootfile-name',
             |      'opt_value': '/tftpboot/path/to/config'},
             |     {'opt_name': 'server-ip-address',
             |      'opt_value': '1.2.3.4'},
             |     {'opt_name': 'tftp-server',
             |      'opt_value': '1.2.3.4'}
             |    ]

        N(R((R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytdhcp_options_for_instanceþscCsdS(s¡Manage the driver's local image cache.

        Some drivers chose to cache images for instances on disk. This method
        is an opportunity to do management of that cache which isn't directly
        related to other calls into the driver. The prime example is to clean
        the cache and remove images which are no longer of interest.

        :param all_instances: nova.objects.instance.InstanceList
        N((R5RGt
all_instances((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytmanage_image_caches
cKs
tƒ‚dS(sïAdd a compute host to an aggregate.

        The counter action to this is :func:`remove_from_aggregate`

        :param nova.context.RequestContext context:
            The security context.
        :param nova.objects.aggregate.Aggregate aggregate:
            The aggregate which should add the given `host`
        :param str host:
            The name of the host to add to the given `aggregate`.
        :param dict kwargs:
            A free-form thingy...

        :return: None
        N(R7(R5RGt	aggregateR8R
((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytadd_to_aggregate$scKs
tƒ‚dS(s÷Remove a compute host from an aggregate.

        The counter action to this is :func:`add_to_aggregate`

        :param nova.context.RequestContext context:
            The security context.
        :param nova.objects.aggregate.Aggregate aggregate:
            The aggregate which should remove the given `host`
        :param str host:
            The name of the host to remove from the given `aggregate`.
        :param dict kwargs:
            A free-form thingy...

        :return: None
        N(R7(R5RGRÓR8R
((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytremove_from_aggregate7scCs
tƒ‚dS(sUndo for Resource Pools.N(R7(R5RGtopRÓR8t	set_error((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytundo_aggregate_operationIscCs
tƒ‚dS(s¡Get connector information for the instance for attaching to volumes.

        Connector information is a dictionary representing the ip of the
        machine that will be making the connection, the name of the iscsi
        initiator and the hostname of the machine as follows::

            {
                'ip': ip,
                'initiator': initiator,
                'host': hostname
            }

        N(R7(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_volume_connectorNscCs
tƒ‚dS(s>Returns nodenames of all nodes managed by the compute service.

        This method is for multi compute-nodes support. If a driver supports
        multi compute-nodes, this method returns a list of nodenames managed
        by the service. Otherwise, this method should return
        [hypervisor_hostname].
        N(R7(R5trefresh((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_available_nodes^scCs,||jƒkrtS||jdtƒkS(s>Return whether this compute service manages a particular node.RÚ(RÛtTrue(R5R–((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytnode_is_availablehscCsiS(ssGet information about instance resource usage.

        :returns: dict of  nova uuid => dict of usage info
        ((R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_per_instance_usageoscCstS(sChecks access of instance files on the host.

        :param instance: nova.objects.instance.Instance to lookup

        Returns True if files of an instance with the supplied ID accessible on
        the host, False otherwise.

        .. note::
            Used in rebuild for HA implementation and required for validation
            of access to instance shared disk files
        (RÍ(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytinstance_on_diskvscCs
||_dS(sRegister a callback to receive events.

        Register a callback to receive asynchronous event
        notifications from hypervisors. The callback will
        be invoked with a single parameter, which will be
        an instance of the nova.virt.event.Event class.
        N(R4(R5tcallback((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytregister_event_listener„s	cCsµ|js&tjdtj|ƒƒdSt|tjƒsMtt	dƒƒ‚ny*tjdtj|ƒƒ|j|ƒWn7t
k
r°}tjtdƒi|d6|d6ƒnXdS(sÐDispatches an event to the compute manager.

        Invokes the event callback registered by the
        compute manager to dispatch the event. This
        must only be invoked from a green thread.
        sDiscarding event %sNs2Event must be an instance of nova.virt.event.EventsEmitting event %ss-Exception dispatching event %(event)s: %(ex)sRtex(
R4tLOGtdebugtsixt	text_typet
isinstancet	virteventtEventt
ValueErrorRt	ExceptionterrorR(R5RRâ((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt
emit_events	cCstS(sÅDelete any lingering instance files for an instance.

        :param instance: nova.objects.instance.Instance
        :returns: True if the instance was deleted from disk, False otherwise.
        (RÜ(R5R((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytdelete_instance_files¦scCstS(sÎTell the caller if the driver requires legacy block device info.

        Tell the caller whether we expect the legacy format of block
        device info to be passed in to methods that expect it.
        (RÜ(R5((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytneed_legacy_block_device_info®scCs
tƒ‚dS(sxSnapshots volumes attached to a specified instance.

        The counter action to this is :func:`volume_snapshot_delete`

        :param nova.context.RequestContext context:
            The security context.
        :param nova.objects.instance.Instance  instance:
            The instance that has the volume attached
        :param uuid volume_id:
            Volume to be snapshotted
        :param create_info: The data needed for nova to be able to attach
               to the volume.  This is the same data format returned by
               Cinder's initialize_connection() API call.  In the case of
               doing a snapshot, it is the image file Cinder expects to be
               used as the active disk after the snapshot operation has
               completed.  There may be other data included as well that is
               needed for creating the snapshot.
        N(R7(R5RGRt	volume_idtcreate_info((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytvolume_snapshot_create·scCs
tƒ‚dS(s>Deletes a snapshot of a volume attached to a specified instance.

        The counter action to this is :func:`volume_snapshot_create`

        :param nova.context.RequestContext context:
            The security context.
        :param nova.objects.instance.Instance instance:
            The instance that has the volume attached.
        :param uuid volume_id:
            Attached volume associated with the snapshot
        :param uuid snapshot_id:
            The snapshot to delete.
        :param dict delete_info:
            Volume backend technology specific data needed to be able to
            complete the snapshot.  For example, in the case of qcow2 backed
            snapshots, this would include the file being merged, and the file
            being merged into (if appropriate).

        :return: None
        N(R7(R5RGRRðtsnapshot_idtdelete_info((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytvolume_snapshot_deleteÍscCs
tƒ‚dS(s{Provide a default root device name for the driver.

        :param nova.objects.instance.Instance instance:
            The instance to get the root device for.
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        :param nova.objects.BlockDeviceMapping root_bdm:
            The description of the root device.
        N(R7(R5RRHtroot_bdm((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytdefault_root_device_nameås
cGs
tƒ‚dS(s=Default the missing device names in the block device mapping.N(R7(R5RRtblock_device_lists((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt!default_device_names_for_instanceñscCs
tƒ‚dS(s™Get the next device name based on the block device mapping.

        :param instance: nova.objects.instance.Instance that volume is
                         requesting a device name
        :param bdms: a nova.objects.BlockDeviceMappingList for the instance
        :param block_device_obj: A nova.objects.BlockDeviceMapping instance
                                 with all info about the requested block
                                 device. device_name does not need to be set,
                                 and should be decided by the driver
                                 implementation if not set.

        :returns: The chosen device name.
        N(R7(R5RRKtblock_device_obj((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytget_device_name_for_instanceöscCstS(sËCheck whether the file format is supported by this driver

        :param fs_type: the file system type to be checked,
                        the validate values are defined at disk API module.
        (RÍ(R5tfs_type((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytis_supported_fs_formats
cCs
tƒ‚dS(sèQuiesce the specified instance to prepare for snapshots.

        If the specified instance doesn't support quiescing,
        InstanceQuiesceNotSupported is raised. When it fails to quiesce by
        other errors (e.g. agent timeout), NovaException is raised.

        :param context:  request context
        :param instance: nova.objects.instance.Instance to be quiesced
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        N(R7(R5RGRRH((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytquiescescCs
tƒ‚dS(sãUnquiesce the specified instance after snapshots.

        If the specified instance doesn't support quiescing,
        InstanceQuiesceNotSupported is raised. When it fails to quiesce by
        other errors (e.g. agent timeout), NovaException is raised.

        :param context:  request context
        :param instance: nova.objects.instance.Instance to be unquiesced
        :param nova.objects.ImageMeta image_meta:
            The metadata of the image of the instance.
        N(R7(R5RGRRH((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt	unquiesce!scCs
|jdƒS(sGet host ID to associate with network ports.

        :param context:  request context
        :param instance: nova.objects.instance.Instance that the network
                         ports will be associated with
        :returns: a string representing the host ID
        R8(R$(R5RGR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytnetwork_binding_host_id/sN(wt__name__t
__module__t__doc__RÍtcapabilitiesR6R9R:R;R>RBRFR=R@R(RQRRRÜRURWRZR\R]R^R_R`RaRbRcRdRfRhRiRoRpRtRvRwR|RR€R…R†R‡RˆR‰RŠR‹RŒRŽRR‘R’R„R“R”R•R—R˜RœRRžRŸR R¡R¢R£R¥R¦RªR¬R­R®R°R±R²R³R´RµR¶R¸R»R½R¿RÀRÂRÄRÆRÇRÈRÉRÊRÌRÎRÏRÐRÒRÔRÕRØRÙRÛRÝRÞRßRáRíRîtpropertyRïRòRõR÷RùRûRýRþRÿR(((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyR-isþ
				
			
		&			
	
	
	
	
	
								
	
									
			
			
	
			
	
	
										
			
														
															cCs³|stj}n|s;tjtdƒƒtjdƒntjtdƒ|ƒy*t	j
d||ƒ}tj|t
ƒSWn1tk
r®tjtdƒƒtjdƒnXdS(sÅLoad a compute driver module.

    Load the compute driver module specified by the compute_driver
    configuration option or, if supplied, the driver name supplied as an
    argument.

    Compute drivers constructors take a VirtAPI object as their first object
    and this must be supplied.

    :param virtapi: a VirtAPI instance
    :param compute_driver: a compute driver name to override the config opt
    :returns: a ComputeDriver instance
    s1Compute driver option required, but not specifiedisLoading compute driver '%s'snova.virt.%ss(Unable to load the virtualization driverN(tCONFtcompute_driverRãRìRtsystexittinfoRRt
import_objectRtcheck_isinstanceR-tImportErrort	exception(R3RR((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pytload_compute_driver:s	
cCs
tjdkS(Nsxenapi.XenAPIDriver(RR(((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt	is_xenapiZs(#RRtoslo_logRtloggingt
oslo_utilsRRåt	nova.conftnovat	nova.i18nRRRRRRRètconfRt	getLoggerRRãRR#R%R)R*R+R,tobjectR-R(RR(((sE/home/tvault/.virtenv/lib/python2.7/site-packages/nova/virt/driver.pyt<module>s2							ÿÿÿÿÿÖ