Installation and configuration

Install

Important

First need to do setting up the environment. All commands are executed only from superuser.

Mode superuser:

sudo -i
  1. Install package:

    • from Python packages repository:

      pip3 install nova-virt-driver
      

Note

To install Nova Virt Driver on Astra Linux (Smolensk) do following:

  1. Connect the provided repository with AccentOS packages.

  2. Install the package with the command:

    sudo apt install -y aos-nova-virt-driver
    

Configure

  1. After installation, the module must be activated by specifying it as a driver in the Nova configuration file /etc/nova/nova.conf. Example:

    [DEFAULT]
    compute_driver = nova_virt_driver.driver.LibvirtDriver
    [libvirt]
    virt_type = kvm
    
  2. Restart nova-compute service:

    # Debian:
    systemctl restart nova-compute.service
    

Settings in Dashboard to change the amount of memory and CPU of instances

Important

Agent module must be installed and configured on the compute nodes before changing the amount of RAM and the number of CPU cores of instance.

  1. Log in to Dashboard, the process is described in the section “Authorization and navigation in the module”.

  2. Go to the “Administrator” section, to the “Flavors” tab. Select the required flavor and click “Update Metadata”.

  3. In the window that opens, set the maximum number of processor cores and RAM for this “Flavor”. Two parameters cpu:maximum and mem:maximum are responsible for this (they must be greater than or equal to the current flavor parameters, for example, for an instance type with 128 MB RAM, mem:maximum must be greater than or equal to 131072 (KB), in the picture below 524288 KB = 512 MB). These parameters indicate what the maximum number of processor cores and RAM (the value of the amount of RAM is indicated in KB). You can set for instance created on the basis of this “Flavor”, that is, you can change the number of processor cores and RAM in the future, after creating and running instance on the fly without restarting it.

    ../../../_images/dash_update_meta_flavor.png

    Updating flavor metadata

  4. Go to the «Project», then to the “Instances” tab. Create instance with the required parameters and the flavor that was configured earlier. Detailed description of the process of creating a instance is available in subsection “Launch instance”. The created instance will have the parameters of the original flavor (VCPUS, RAM, Disk size, etc.).

  5. Select instance created based on flavor with updated metadata, use the «Hot Plug» action to change the number of CPU cores and RAM on the instance on the fly.

  6. You can also change the processor cores and RAM of instance manually by updating the instance’s metadata.

  7. In the window that opens, set the required number of processor cores and RAM for this instance. Two parameters are responsible for this: cpu:current and mem:current. These values must not exceed the cpu:maximum and mem:maximum values specified for the “Flavor”. These values must not exceed the values specified for the “Flavor”. The amount of RAM and the number of processor cores will be applied without rebooting if instance guest system supports hot plugging of processor cores and RAM.

    ../../../_images/dash_update_meta_instance.png

    Instances list

Functionality is described in more detail in the corresponding section.