The main configuration information is provided in OpenNebula configuration. Here you can find additional configuration details.
Note that these are the default values and could be overridden in the IMAGE and VM templates!
The addon could use fstrim/fsthaw to create consistent snapshots/backups. The option enables the host side of the setup. The qemu-guest-agent must be running inside the VM.
-
Default:
FEATURES = [ PAE = "no", ACPI = "yes", APIC = "no", HYPERV = "no", GUEST_AGENT = "no" ] -
Suggested:
FEATURES = [ PAE = "no", ACPI = "yes", APIC = "no", HYPERV = "no", GUEST_AGENT = "yes" ]
Add defaults for io and discard.
-
Default:
DISK = [ driver = "raw" , cache = "none"] -
Suggested:
DISK = [ driver = "raw" , cache = "none" , io = "native" , discard = "unmap" ]
Or /var/lib/one/remotes/vmm/kvm/kvmrc, for OpenNebula before version 5.6.
Uncomment to enable.
-
Default:
#DEFAULT_ATTACH_CACHE=none -
Suggested:
DEFAULT_ATTACH_CACHE=none
Uncomment to enable
-
Default:
#DEFAULT_ATTACH_DISCARD=unmap -
Suggested:
DEFAULT_ATTACH_DISCARD=unmap
Uncomment and set to native
-
Default:
#DEFAULT_ATTACH_IO= -
Suggested:
DEFAULT_ATTACH_IO=native
!!! Warning !!! These features are changing the defalt behavior of OpenNebula and should be used when the StorPool addon is the only storage driver, and when used for both SYSTEM and IMAGE datastores!
The feature is working only with recent version of StorPool. Please contact StorPool Support for details.
The StorPool addon can re-purpose the OpenNebula's interface for VM snapshots to do atomic snapshots on all VM disks at once. In addition, there is an option to enable FSFREEZE before snapshotting and FSTHAW after the snapshots are taken.
To enable the feature do the following changes.
-
In
/etc/one/oned.conf:-
Edit the
VM_MADconfiguration forkvmand change theARGUMENTSline as follows:ARGUMENTS = "-t 15 -r 0 kvm -l snapshotcreate=snapshot_create-storpool,snapshotrevert=snapshot_revert-storpool,snapshotdelete=snapshot_delete-storpool", -
Edit the
VM_MADconfiguration forkvmand changeKEEP_SNAPSHOTSto 'yes':KEEP_SNAPSHOTS = "yes",
-
-
In
/var/lib/one/remotes/addon-storpoolrc:-
Add
VMSNAPSHOT_OVERRIDEconfiguration variable:VMSNAPSHOT_OVERRIDE=1 -
To enable the optional
fsfreeze/fsthaw:VMSNAPSHOT_FSFREEZE=1
-
Please restart the opennebula service to activate the changes.
To tell the OpenNebula's scheduler to deploy the VMs only on StorPool backed SYSTEM datastores, set
SCHED_DS_REQUIREMENTS in the VM template:
SCHED_DS_REQUIREMENTS="TM_MAD=storpool"
Using sunstone, it is located in "Update VM template" -> "Scheduling" -> "Placement" -> "Datastore Requirements".
Set the "Expression" to TM_MAD=storpool.
Define an OpenNebula cluster selecting only StorPool backed SYSTEM and IMAGE datastores. Keep in mind that in this case the images used in the VM templates must be on the datastore selected in the cluster!