Blazar

De TeriaHowto
Sauter à la navigation Sauter à la recherche

Let's experiment Blazar, Openstack dedicated service for resource reservation.

Concept

Imagine this situation : you provides two services, one with high priority, the other one with low priority. During the week, each service runs VMs on multiple node with auto-scaling capability (i.e. another VMs are automatically provisionned if the workload increases). You know that during the week-end, your higher priority service will have more demand and you don't want your lower priority service starving it from resources.
Blazar brings the possibility to reserve dedicated compute nodes for your high prority service for a time period, say, the week-end.
Best of all, unreserved compute nodes managed by Blazar can run preemptible VMs, avoiding unused computing power.

Installation / Configuration

Kolla-ansible is used to deploy our private cloud.

Enable Blazar in globals.yml

enable_blazar: "yes"
kolla_enable_tls_internal: "no"
kolla_enable_tls_backend: "no"

Note that TLS should be disabled (especially for internal traffic). This is a current limitation identified.

Activate preemptible instances in nova-scheduler

On the Ansible deploy host, the file should be config/nova/nova-scheduler.conf

[blazar:physical:host]
allow_preemptibles = true

Create a dedicated flavor for preemptible instances

For the sake of simplicity, only two flavors are going to be used :

  • a "normal" (no preemption)
  • a preemptible
# normal flavor
openstack flavor create --id 1 --ram 512 --disk 1 --vcpus 1 g1
# preemptible flavor
openstack flavor create --id 2 --ram 512 --disk 1 --vcpus 1 --property blazar:preemptible=true g1.preempt

Action

Book hosts for blazar

The hosts you want to reserve for blazar must not belong to aggregates.

openstack reservation host create compute1.cloud.ld
openstack reservation host create compute4.cloud.ld
openstack reservation host list
+----+---------------------+-------+-----------+----------+
| id | hypervisor_hostname | vcpus | memory_mb | local_gb |
+----+---------------------+-------+-----------+----------+
| 8  | compute1.cloud.ld   |     2 |      9664 |       52 |
| 4  | compute4.cloud.ld   |     2 |      5632 |       22 |
+----+---------------------+-------+-----------+----------+
visualization of compute resources in Horizon