def check_instance_shared_storage_local(self, context, instance):
    dirpath = libvirt_utils.get_instance_path(instance)
    if (not os.path.exists(dirpath)):
        return None
    (fd, tmp_file) = tempfile.mkstemp(dir=dirpath)
    LOG.debug('Creating tmpfile %s to verify with other compute node that the instance is on the same shared storage.', tmp_file, instance=instance)
    os.close(fd)
    return {'filename': tmp_file}
def check_instance_shared_storage_local(self, context, instance):
    dirpath = libvirt_utils.get_instance_path(instance)
    if (not os.path.exists(dirpath)):
        return None
    (fd, tmp_file) = tempfile.mkstemp(dir=dirpath)
    LOG.debug('Creating tmpfile %s to verify with other compute node that the instance is on the same shared storage.', tmp_file, instance=instance)
    os.close(fd)
    return {'filename': tmp_file}