- If the API response returns only 1 object, it won't be array wrapped,
causing issues when formatting the response to a dataset. Now
transformApiResponseToDataset always casts the response to an array.
Signed-off-by: Victor Hansson <vhansson@opennebula.io>
(cherry picked from commit 51ef95d720)
- Incremental backups only keep the last snapshot, to be used as base in
the next one.
- Restore operation deletes the previous snapshots, because at that
point the chain is reset and they're no longer going to be used.
- Starting a new FULL backup also deletes previous inc snapshots.
- Refactor the remote execution logic to make it more composable.
Signed-off-by: Guillermo Ramos <gramos@opennebula.io>
(cherry picked from commit 1790b5f3f9ac55e3149f5344580330c27d5585df)
(cherry picked from commit 7ddf9b3b72)
Implementation overview:
- Incremental points are saved as dedicated rbd snapshots under the
"one_backup_<increment_id>" namespace. This snapshots are used to
generate delta files in rbdiff format.
- The rbdiff formats are stored in the backup server to restore the rbd volumes.
- The restore process is performed directly on the Ceph cluster
importing the base image (first full backup in the chain, rbd import)
and then applying the increments (rbd import-diff) up to the target
increment.
- Two new pseudo-protocols has been implemented to adopt the restore
pattern above (restic+rbd, rsync+rbd). This protocols bundle of the
rbdiff files in a tarball for transfer from the backup server. Note:
reconstruct process uses the Ceph BRIDGE_LIST and not the backup
server (as opposed to qcow2 backups)
Other bug fixes
- This commit also fixes#6741, resetting the backup chain after a
restore
- The original ceph drivers do not receive the full action information,
this now has been fixed by including VM information in the STDIN string sent
to the driver.
Compatibility note.
- backup actions should return now the backup format used raw, rbd, ...
If not provided oned (6.10.x) will use raw as a default to accommodate any
third party driver implementation. It is recommended to include this
third argument.
Signed-off-by: Guillermo Ramos <gramos@opennebula.io>
Co-authored-by: Guillermo Ramos <gramos@opennebula.io>
(cherry picked from commit 5f7b370c52)
- oned load only last 2 history records (not the full list)
- Dump all history records only if needed in VirtualMachine::to_xml.
- Dump conforms XML schecam and removes VM template from history records.
Speed up of onevm show command:
- for small SQLite DB is for VM with 500 histories: 130 ms down to 5 ms
- for big MySQL DB VM with 687 histories: 1000 ms down to 200 ms
(cherry picked from commit e13c329db4)
* Correctly displays the VM disks when restoring a backup from the VM
action menu
Signed-off-by: Victor Hansson <vhansson@opennebula.io>
(cherry picked from commit 8f0d20580e)
This feature let's cloud admin to proxy VM connections to any service through the hypervisor. VMs uses a link local IP that is forwarded to a local proxy. This simplifies VM network requirements, e.g. to access gateway, vaults, configuration services etc...
Implementation:
- Use network namespaces to isolate VNET networking. ip netns command is executed through a wrapper to limit sudo access to commands.
- Add tproxy.rb app to manage a group of daemons on HV nodes.
- Use unix sockets for communication between proxy peers. "Inner" proxy runs in the netns without any network access. "Outer" proxy handles HV connections to services.
- Use OpenNebulaNetwork.conf + 'onehost sync -f' for configuration. Proxy can be defined per network.
NOTE: This commits does not include modifications to OpenNebulaNetwork.conf
(cherry picked from commit b1ef4332e5)
* Now displays hostname next to the host in the card view
* Also displays hostname in the list view
Signed-off-by: Victor Hansson <vhansson@opennebula.io>
* It looks like `onedb purge-history` sometimes fails to delete some history records.
* Delete all history records with SEQ greater then VM/HISTORY_RECORDS/HISTORY/SEQ, which should be the last record
(cherry picked from commit a3c4776468)
* Fix Host NUMA nodes after VM migration
* Move template parsing to HostShareCapacity
+ add warning about unsafe pointer usage
(cherry picked from commit 0cde7d96a2)
* Now instantiates the correct number of instances specified for a
service ServiceTemplate
* Default number of instances set to 1
Signed-off-by: Victor Hansson <vhansson@opennebula.io>
(cherry picked from commit 212aa91a3c)
* Cleanup oned in case of initialization error
* Fix monitoring after onemonitord restart. The code includes a "hook" point in case a driver is re-started so custom code can be executed. InformationManager sends the list of hosts and raft status in this case.
* B #5801: Update error msg, in case of duplicated drivers
(cherry picked from commit 7b07def90e)