openstack nova - Murray-LIANG/forgetful GitHub Wiki
Nova
Services
- nova-api
- nova-scheduler
- nova-compute
- nova-conductor
- Hypervisor
Where the services run
Generally, the api, scheduler, conductor are running on Control Node.
compute, Hypervisor are running on Compute Node.
General flow
- User (End user or other services) sends requests to
nova-apito create a VM instance. nova-apisends message toMessage Queueto asknova-schedulerto schedule aCompute Nodeto create the VM.nova-schedulergets the message and pick aCompute Nodevia a filter algorithm, then sends message to let thatCompute Node(A) to create VM.Compute Node(A) gets the message, uses theHypervisorto boot the VM.- Any update to the DB will be executed by messaging the
nova-conductor.
Config hypervisor driver
In /etc/nova/nova.conf, set compute_driver to libvirt.libvirtDriver.
Scheduler
User specifies the Flavor to create the VM. nova-scheduler will choose
the Compute Node.
Flavor defines VCPU, RAM, Disk and Metadata.
In /etc/nova/nova.conf, scheduler_driver, scheduler_available_filters
and scheduler_default_filter settings affect the behavior of scheduler.
Filter scheduler
The default scheduler. Two steps:
- Filter to select the
Compute Nodemeeting the requirements. - Weight the
Compute Nodeof step 1.
scheduler_driver = nova.scheduler.filter_scheduler.FilterScheduler
# Available filters
scheduler_available_filters = nova.scheduler.filters.all_filters
# Filte in below order
scheduler_default_filters = RetryFilter, AvailabilityZoneFilter,
RamFilter, DiskFilter, ComputeFilter,
ComputeCapabilitiesFilter, ImagePropertiesFilter,
ServerGroupAntiAffinityFilter, ServerGroupAffinityFilter