Description of problem: When creating a VM via REST from a template with ballooning=false (e.g. a high performance template) then if memory_policy element exists in api query without specifically setting the ballooning attribute (even an empty memory_policy element without any attributes), then the ballooning is always set to true, regardless to template ballooning settings. This issue is reproduced for all VM types (not just high performance) and it causes the VM created by rest to differ from the one created by webadmin for that specific scenario. Note that for web-ui it's always reproduced since a VM on web-ui is always created with memory_policy element set. Version-Release number of selected component (if applicable): 4.4.4 How reproducible: 100% Steps to Reproduce: 1. create a template" with ballooning=false (template->Resource Allocation->"Memory Ballooning Enabled" is disabled). 2. create a VM via REST query that is based on that template in (1) and includes a "memory_policy" element without the "ballooning" attribute : e.g. <vm> <cluster> <name>cluster</name> </cluster> <name>vm1</name> <template><name>temp_with_balloon_disabled</name></template> <memory_policy> <guaranteed>10</guaranteed> </memory_policy> </vm> OR create a VM via web-ui that is based on that template in (1). Actual results: the created provisioned VM "vm1" is configured with ballooning=true Expected results: the created provisioned VM "vm1" should be configured with ballooning=false
*** This bug has been marked as a duplicate of bug 1897532 ***
I'm reopening this bug. In bug 1897532 the issue is about creating VM pool and taking the ballooning settings from the template. Here, we have the flow of creating a VM from template. Sharon, on the second step to reproduce: "OR create a VM via web-ui that is based on that template in (1)." I didn't manage to reproduce it via the webadmin. Did you mean anything else? On the API it does reproduce.
(In reply to Liran Rotenberg from comment #2) > I'm reopening this bug. > > In bug 1897532 the issue is about creating VM pool and taking the ballooning > settings from the template. > > Here, we have the flow of creating a VM from template. > > Sharon, on the second step to reproduce: > "OR > create a VM via web-ui that is based on that template in (1)." > > I didn't manage to reproduce it via the webadmin. Did you mean anything > else? On the API it does reproduce. web-ui means VM portal and not webadmin. The VM portal callls the API for creating a VM based on a template and set the "memory_policy" element for setting the VM's memory size. But as mentioned, it's reproduced via the API directly as well.
> (In reply to Liran Rotenberg from comment #2) > > I'm reopening this bug. > > > > In bug 1897532 the issue is about creating VM pool and taking the ballooning > > settings from the template. > > > > Here, we have the flow of creating a VM from template. > > > > Sharon, on the second step to reproduce: > > "OR > > create a VM via web-ui that is based on that template in (1)." > > > > I didn't manage to reproduce it via the webadmin. Did you mean anything > > else? On the API it does reproduce. > > web-ui means VM portal and not webadmin. The VM portal callls the API for > creating a VM based on a template and set the "memory_policy" element for > setting the VM's memory size. > But as mentioned, it's reproduced via the API directly as well. It was raised on web-ui by this issue: https://github.com/oVirt/ovirt-web-ui/pull/1362#pullrequestreview-590415468
verified on ovirt-engine-4.4.5.6-0.11.el8ev.noarch both scenarios - rest API and VM Portal
This bugzilla is included in oVirt 4.4.5 release, published on March 18th 2021. Since the problem described in this bug report should be resolved in oVirt 4.4.5 release, it has been closed with a resolution of CURRENT RELEASE. If the solution does not work for you, please open a new bug report.