Default Attributes for KVM Driver:
|Assignee:||Ruben S. Montero||% Done:|
|Target version:||Release 3.8|
|Affected Versions:||OpenNebula 3.6|
According to OpenNebula 3.6 documentation, CPU is a valid default attribute for KVM driver:
There are some attributes required for KVM to boot a VM. You can set a suitable defaults for them so, all the VMs get needed values. These attributes are set in /etc/one/vmm_exec/vmm_exec_kvm.conf. The following can be set for KVM:
- emulator, path to the kvm executable. You may need to adjust it to your ditsro
- os, the attraibutes: kernel, initrd, boot, root, kernel_cmd, and arch
- features, attributes: acpi, pae
- dis, attributes driver and cache. All disks will use that driver and caching algorithm
- nic, attribute filter.
However, when attempting to define this value in the driver file "exec/vmm_exec_kvm.conf", ONE ignores it. Moreover, that value is missing from the Valid attributes in that file:
From "/one/src/vmm_mad/exec/vmm_exec_kvm.conf" v 3.6,
Valid attributes are:
- - emulator
- - os [kernel,initrd,boot,root,kernel_cmd,arch]
- - vcpu
- - features [acpi, pae]
- - disk [driver, cache]
- - nic [filter]
Was "CPU" attribute removed intentionally from the supported defaults and the documentation is outdated? Or is it a bug with OpenNebula KVM driver after migration from earlier versions?
#1 Updated by Ruben S. Montero almost 9 years ago
- Description updated (diff)
- Category changed from Drivers - Auth to Documentation
- Status changed from New to Closed
- Assignee set to Ruben S. Montero
- Target version set to Release 3.8
- Resolution set to fixed
Thanks for the head up. This is an error in the documentation. CPU and MEMORY are no longer supported as driver defaults since the addition of quota management to the OpenNebula core. Now a VM has to have those parameters defined, so they cannot be defined in the driver as a default.
#2 Updated by K S almost 9 years ago
Thanks for the follow-up. You probably want to give another example as the "CPU" example is not valid anymore:
And the following driver configuration files: For example, if the user wants to set a default value for CPU requirements for all of their KVM domain definitions, simply edit the /etc/one/vmm_exec/vmm_exec_kvm.conf file and set a CPU=0.6 into it. Now, when defining a template to be sent to a KVM resource, the user has the choice of “forgetting” to set the CPU requirement, in which case it will default to 0.6.