Bug 1173117 - Optimizer suggest migrating VMs which does not allow migration
Summary: Optimizer suggest migrating VMs which does not allow migration
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-optimizer
Version: 3.5.0
Hardware: All
OS: All
low
medium
Target Milestone: ovirt-3.6.0-rc
: 3.6.0
Assignee: Martin Sivák
QA Contact: Shira Maximov
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-12-11 13:29 UTC by Lukas Svaty
Modified: 2016-03-09 20:21 UTC (History)
7 users (show)

Fixed In Version: ovirt-optimizer-0.9
Doc Type: Bug Fix
Doc Text:
Cause: Pin to host rules acted together with migration settings in unexpected way. Consequence: Non-migratable VM cound not be started (it caused hard constraint violation for the solution). Fix: Pin to host rules and non-migratable setting are only enforced together during migration. Result: Non-migratable VM is able to start in the solution.
Clone Of:
Environment:
Last Closed: 2016-03-09 20:21:34 UTC
oVirt Team: SLA
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:0427 normal SHIPPED_LIVE ovirt-optimizer bug fix and enhancement update 2016-03-10 01:19:39 UTC
oVirt gerrit 36676 master MERGED Ignore PinToHost rules when starting a new VM Never

Description Lukas Svaty 2014-12-11 13:29:25 UTC
Description of problem:
When we are running optimizer on cluster with VMs that are running on specific host and does not have migration allowed. Optimizer suggest solution of migrating VMs with status:
Status: Solution is not doable! There are hard constraint violations.

That is nice, but I have no idea what hard constraint I any of my multiple VM are is violated.

Better solution is to let optimizer know he should not suggest migrating these VMs. 

Or suggest user to allow migration on this VM. This is also accaptable as there will be no big change to rules.

Version-Release number of selected component (if applicable):
0.4.5

How reproducible:
100%

Steps to Reproduce:
1. 2 hosts blue, purple, 4 vms vm1-4 pinned to blue, migration not allowed on VMs
2. Cluster policy - None
3. See optimizer result

Actual results:
Status: Solution is not doable! There are hard constraint violations.

No VM starts are requested at this moment.
Migration / Start steps
vm3 → purple 	

Target state
host 	vm 	memory [all in GB] 	 
  	  	used 	available 	 
purple 	  	2.0 	7.7 	
  	vm3 	2.0 	2.0 	
blue 	  	6.0 	7.7 	
  	vm-4 	2.0 	2.0 	 
  	vm2 	2.0 	2.0 	 
  	vm1 	2.0 	2.0 	 

Expected results:
Either new rule for optimizer so it won't try to optimizer cluster but migrating unmigratable VMs or New ui-plugin step that suggests making VM migratable.

Additional info:
I've got some spammed debug log of optimizer so If necessary, it won't be a problem. :)

Comment 1 Martin Sivák 2014-12-11 14:37:35 UTC
Optimizer uses probability based algorithms. So if there is no solution it gives you the best it has and tells you that it is not valid as a whole.

Optimizer already has rules that consider a migration of pinned VM to be hard constraint violation. That is why it was able to tell you that in the fist place.

The only change that can be done here is to make it more obvious that the solution is not valid. I do not have a per step score so I can't highlight the issue easily.

I could implement a new Explain button, that would (on demand) compute the score step by step and display it somehow. It is expensive in terms of cpu/memory though.

Comment 2 Martin Sivák 2014-12-15 09:48:57 UTC

*** This bug has been marked as a duplicate of bug 1173551 ***

Comment 3 Shira Maximov 2015-01-07 15:35:17 UTC
This is not the some bug, 
This bug is that the optimizer suggest migrating VMs which does not allow migration.

The other bug  is that the Optimizer should not propose steps if solution is not doable.

Comment 6 Shira Maximov 2015-10-12 08:07:40 UTC
verified on : 
 Red Hat Enterprise Virtualization Manager Version: 3.6.0-0.18.el6

Comment 7 Julie 2016-02-22 04:29:16 UTC
If this bug requires doc text for errata release, please provide draft text in the doc text field in the following format:

Cause:
Consequence:
Fix:
Result:

The documentation team will review, edit, and approve the text.

If this bug does not require doc text, please set the 'requires_doc_text' flag to -.

Comment 9 errata-xmlrpc 2016-03-09 20:21:34 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-0427.html


Note You need to log in before you can comment on or make changes to this bug.