The nova.scheduler.manager Module

Scheduler Service

class SchedulerManager(scheduler_driver=None, *args, **kwargs)

Bases: nova.manager.Manager

Chooses a host to run instances on.

RPC_API_VERSION = '2.6'
create_volume(context, volume_id, snapshot_id, reservations=None, image_id=None)
get_backdoor_port(context)
live_migration(*args, **kwargs)
post_start_hook()

After we start up and can receive messages via RPC, tell all compute nodes to send us their capabilities.

prep_resize(context, image, request_spec, filter_properties, instance, instance_type, reservations)

Tries to call schedule_prep_resize on the driver. Sets instance vm_state to ACTIVE on NoHostFound Sets vm_state to ERROR on other exceptions

run_instance(context, request_spec, admin_password, injected_files, requested_networks, is_first_time, filter_properties)

Tries to call schedule_run_instance on the driver. Sets instance vm_state to ERROR on exceptions

select_hosts(context, request_spec, filter_properties)

Returns host(s) best suited for this request_spec and filter_properties

show_host_resources(context, host)

Shows the physical/usage resource given by hosts.

Parameters:
  • context – security context
  • host – hostname
Returns:

example format is below:

{'resource':D, 'usage':{proj_id1:D, proj_id2:D}}
D: {'vcpus': 3, 'memory_mb': 2048, 'local_gb': 2048,
    'vcpus_used': 12, 'memory_mb_used': 10240,
    'local_gb_used': 64}

update_service_capabilities(context, service_name, host, capabilities)

Process a capability update from a service node.

Previous topic

The nova.scheduler.host_manager Module

Next topic

The nova.scheduler.multi Module

This Page