| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Codecov ReportAttention: Patch coverage is 0% with 35 lines in your changes missing coverage. Please review.
@@ Coverage Diff @@
## 4.19 #8911 +/- ##
============================================
+ Coverage 15.07% 15.28% +0.20%
- Complexity 11168 11580 +412
============================================
Files 5406 5406
Lines 472795 490142 +17347
Branches 57834 66027 +8193
============================================
+ Hits 71282 74904 +3622
- Misses 393585 406937 +13352
- Partials 7928 8301 +373
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Sorry, something went wrong.
|
@sureshanaparti a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
Sorry, something went wrong.
|
Packaging result [SF]: ✖️ el7 ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 9252 |
Sorry, something went wrong.
|
Packaging result [SF]: ✖️ el7 ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 9256 |
Sorry, something went wrong.
|
@JoaoJandre a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
Sorry, something went wrong.
|
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9262 |
Sorry, something went wrong.
|
@sureshanaparti could we run de CI here? |
Sorry, something went wrong.
|
@DaanHoogland a [SL] Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
Sorry, something went wrong.
|
[SF] Trillian Build Failed (tid-9870) |
Sorry, something went wrong.
|
[SF] Trillian Build Failed (tid-9873) |
Sorry, something went wrong.
|
[SF] Trillian test result (tid-9884)
|
Sorry, something went wrong.
|
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch. |
Sorry, something went wrong.
|
@DaanHoogland a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
Sorry, something went wrong.
|
Packaging result [SF]: ✖️ el7 ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 9536 |
Sorry, something went wrong.
|
@JoaoJandre a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
Sorry, something went wrong.
|
Packaging result [SF]: ✔️ el7 ✖️ el8 ✖️ el9 ✔️ debian ✖️ suse15. SL-JID 9547 |
Sorry, something went wrong.
|
@DaanHoogland a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
Sorry, something went wrong.
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 11026 |
Sorry, something went wrong.
|
@rohityadavcloud a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests |
Sorry, something went wrong.
|
[SF] Trillian test result (tid-11411)
|
Sorry, something went wrong.
no issues |
Sorry, something went wrong.
@rohityadavcloud I would like to have it merged into 4.20. But we are still missing a review/LGTM. It probably will not make it. |
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM! I tested this PR in a local environment by live migrating a VM with storage between NFS/Local/SMP as well as force-deleting a template and then migrating it, which worked perfectly fine as the volume was consolidated and the VM did not get corrupted.
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM based on manual testing on Oracle Linux 9 with NFS, local and shared mountpoint storages.
Sorry, something went wrong.
great ! |
Sorry, something went wrong.
|
@JoaoJandre this has base branch 4.19. It is not really a fix, is it? Will we merge? |
Sorry, something went wrong.
@DaanHoogland In order to fix the situations explained in https://github.com/apache/cloudstack/pull/7615 and https://github.com/apache/cloudstack/pull/8834, we consolidate the volume when its template is deleted. |
Sorry, something went wrong.
ok, @weizhouapache just leaving it with the author/RM |
Sorry, something went wrong.
@DaanHoogland @weizhouapache I was originally not going to merge this as it was mainly created as a normalization PR. However, it is fixing a bug that has been reported in #7615 and #8834. This PR has also been extensively tested (see #8911 (comment), #8911 (review) and #8911 (review)) so we should be safe to merge it. Also, the failures in #8911 (comment) do not seem related: 2024-09-06 23:06:20,361 - CRITICAL - EXCEPTION: test_02_unsecure_vm_migration: ['Traceback (most recent call last):\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 60, in testPartExecutor\n yield\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 622, in run\n testMethod()\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1211, in test_02_unsecure_vm_migration\n vm = self.deploy_vm(src_host)\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1154, in deploy_vm\n hostid=origin_host.id)\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/lib/base.py", line 691, in create\n virtual_machine = apiclient.deployVirtualMachine(cmd, method=method)\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackAPI/cloudstackAPIClient.py", line 3981, in deployVirtualMachine\n response = self.connection.marvinRequest(command, response_type=response, method=method)\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackConnection.py", line 381, in marvinRequest\n raise e\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackConnection.py", line 376, in marvinRequest\n raise self.__lastError\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackConnection.py", line 105, in __poll\n % async_response)\n', 'Exception: Job failed: {accountid : \'f8c22aaf-6c54-11ef-8280-1e009600027b\', account : \'admin\', domainid : \'ca87b0c6-6c54-11ef-8280-1e009600027b\', domainpath : \'ROOT\', userid : \'f8c3bd75-6c54-11ef-8280-1e009600027b\', cmd : \'org.apache.cloudstack.api.command.admin.vm.DeployVMCmdByAdmin\', jobstatus : 2, jobprocstatus : 0, jobresultcode : 530, jobresulttype : \'object\', jobresult : {errorcode : 530, errortext : \'Unable to start a VM [1826588c-f837-4e93-a5e8-696cbee3ab33] due to [Unable to create a deployment for VM instance {"id":366,"instanceName":"i-256-366-VM","type":"User","uuid":"1826588c-f837-4e93-a5e8-696cbee3ab33"}].\'}, jobinstancetype : \'VirtualMachine\', jobinstanceid : \'1826588c-f837-4e93-a5e8-696cbee3ab33\', created : \'2024-09-06T23:03:31+0000\', completed : \'2024-09-06T23:03:42+0000\', jobid : \'1d13a744-a414-43a6-b25e-384ff838c22f\'}\n']
2024-09-07 00:12:15,221 - CRITICAL - EXCEPTION: test_03_secured_to_nonsecured_vm_migration: ['Traceback (most recent call last):\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 60, in testPartExecutor\n yield\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 622, in run\n testMethod()\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1229, in test_03_secured_to_nonsecured_vm_migration\n vm = self.deploy_vm(secure_host)\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1154, in deploy_vm\n hostid=origin_host.id)\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/lib/base.py", line 691, in create\n virtual_machine = apiclient.deployVirtualMachine(cmd, method=method)\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackAPI/cloudstackAPIClient.py", line 3981, in deployVirtualMachine\n response = self.connection.marvinRequest(command, response_type=response, method=method)\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackConnection.py", line 381, in marvinRequest\n raise e\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackConnection.py", line 376, in marvinRequest\n raise self.__lastError\n', ' File "/usr/local/lib/python3.6/site-packages/marvin/cloudstackConnection.py", line 105, in __poll\n % async_response)\n', 'Exception: Job failed: {accountid : \'f8c22aaf-6c54-11ef-8280-1e009600027b\', account : \'admin\', domainid : \'ca87b0c6-6c54-11ef-8280-1e009600027b\', domainpath : \'ROOT\', userid : \'f8c3bd75-6c54-11ef-8280-1e009600027b\', cmd : \'org.apache.cloudstack.api.command.admin.vm.DeployVMCmdByAdmin\', jobstatus : 2, jobprocstatus : 0, jobresultcode : 530, jobresulttype : \'object\', jobresult : {errorcode : 530, errortext : \'Unable to start a VM [03dfcf15-bd8f-4ace-bdd1-115323402a2a] due to [Unable to create a deployment for VM instance {"id":367,"instanceName":"i-256-367-VM","type":"User","uuid":"03dfcf15-bd8f-4ace-bdd1-115323402a2a"}].\'}, jobinstancetype : \'VirtualMachine\', jobinstanceid : \'03dfcf15-bd8f-4ace-bdd1-115323402a2a\', created : \'2024-09-06T23:09:50+0000\', completed : \'2024-09-07T00:09:53+0000\', jobid : \'eb2b43c4-f75f-4efb-a4d0-741217fb3576\'}\n']
2024-09-07 00:12:15,373 - CRITICAL - EXCEPTION: test_03_secured_to_nonsecured_vm_migration: ['Traceback (most recent call last):\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 60, in testPartExecutor\n yield\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 625, in run\n self.tearDown()\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1067, in tearDown\n self.secure_all_hosts()\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1144, in secure_all_hosts\n self.check_connection(secured=\'true\', host=host)\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1174, in check_connection\n ", actual is: " + host.details.secured)\n', "Exception: Host detail 'secured' was expected: true, actual is: false\n"]
2024-09-07 00:14:37,744 - CRITICAL - EXCEPTION: test_04_nonsecured_to_secured_vm_migration: ['Traceback (most recent call last):\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 60, in testPartExecutor\n yield\n', ' File "/usr/lib64/python3.6/unittest/case.py", line 618, in run\n self.setUp()\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1063, in setUp\n self.secure_all_hosts()\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1144, in secure_all_hosts\n self.check_connection(secured=\'true\', host=host)\n', ' File "/marvin/tests/smoke/test_vm_life_cycle.py", line 1174, in check_connection\n ", actual is: " + host.details.secured)\n', "Exception: Host detail 'secured' was expected: true, actual is: false\n"]
|
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Description
Currently, when a volume that was created with linked clone is live migrated from an NFS storage to another NFS storage in KVM, it continues to have the template as a backing file on the destination storage. In all other cases, such as NFS to SharedMountPoint, the volume is consolidated with its backing file during migration.
This special case adds unnecessary complexity to ACS; In most cases, performing the migration without consolidating the volume does not significantly optimize resource usage. On the other hand, when consolidating the volume with its backing file, the hypervisor detects empty sectors and removes them from the final volume, therefore, consolidating the volume can reduce storage usage.
Instead of only maintaining linked clone only on NFS to NFS migration, we now maintain it when migrating between NFS, shared mount-point and local storage, as all of these are file based and have no reason to always consolidate the volumes.
In order to fix the situations explained in
#7615 and #8834, we consolidate the volume when its template is deleted.
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?
I've tested creating a VM and migrating between NFS/SMP/Local storage, all migrations were successful, the template was copied to the storage and the VM was not corrupted.
I've also tested creating a VM, force deleting its template and then migrating it, the migration consolidated the volume, and the VM was not corrupted.