def update_status(self):
    'Retrieve status info from libvirt.'

    def _get_disk_available_least():
        'Return total real disk available least size.\n\n            The size of available disk, when block_migration command given\n            disk_over_commit param is FALSE.\n\n            The size that deducted real instance disk size from the total size\n            of the virtual disk of all instances.\n\n            '
        disk_free_gb = disk_info_dict['free']
        disk_over_committed = self.driver._get_disk_over_committed_size_total()
        available_least = ((disk_free_gb * units.Gi) - disk_over_committed)
        return (available_least / units.Gi)
    LOG.debug('Updating host stats')
    disk_info_dict = self.driver._get_local_gb_info()
    data = {}
    data['supported_instances'] = self.driver._get_instance_capabilities()
    data['vcpus'] = self.driver._get_vcpu_total()
    data['memory_mb'] = self.driver._get_memory_mb_total()
    data['local_gb'] = disk_info_dict['total']
    data['vcpus_used'] = self.driver._get_vcpu_used()
    data['memory_mb_used'] = self.driver._get_memory_mb_used()
    data['local_gb_used'] = disk_info_dict['used']
    data['hypervisor_type'] = self.driver._get_hypervisor_type()
    data['hypervisor_version'] = self.driver._get_hypervisor_version()
    data['hypervisor_hostname'] = self.driver._get_hypervisor_hostname()
    data['cpu_info'] = self.driver._get_cpu_info()
    data['disk_available_least'] = _get_disk_available_least()
    data['pci_passthrough_devices'] = self.driver._get_pci_passthrough_devices()
    self._stats = data
    return data
Retrieve status info from libvirt.
def update_status(self):
    

    def _get_disk_available_least():
        'Return total real disk available least size.\n\n            The size of available disk, when block_migration command given\n            disk_over_commit param is FALSE.\n\n            The size that deducted real instance disk size from the total size\n            of the virtual disk of all instances.\n\n            '
        disk_free_gb = disk_info_dict['free']
        disk_over_committed = self.driver._get_disk_over_committed_size_total()
        available_least = ((disk_free_gb * units.Gi) - disk_over_committed)
        return (available_least / units.Gi)
    LOG.debug('Updating host stats')
    disk_info_dict = self.driver._get_local_gb_info()
    data = {}
    data['supported_instances'] = self.driver._get_instance_capabilities()
    data['vcpus'] = self.driver._get_vcpu_total()
    data['memory_mb'] = self.driver._get_memory_mb_total()
    data['local_gb'] = disk_info_dict['total']
    data['vcpus_used'] = self.driver._get_vcpu_used()
    data['memory_mb_used'] = self.driver._get_memory_mb_used()
    data['local_gb_used'] = disk_info_dict['used']
    data['hypervisor_type'] = self.driver._get_hypervisor_type()
    data['hypervisor_version'] = self.driver._get_hypervisor_version()
    data['hypervisor_hostname'] = self.driver._get_hypervisor_hostname()
    data['cpu_info'] = self.driver._get_cpu_info()
    data['disk_available_least'] = _get_disk_available_least()
    data['pci_passthrough_devices'] = self.driver._get_pci_passthrough_devices()
    self._stats = data
    return data