Bug 1039614

Summary: Migrate VM only for local maintenance
Product: Red Hat Enterprise Virtualization Manager Reporter: Greg Padgett <gpadgett>
Component: ovirt-hosted-engine-haAssignee: Greg Padgett <gpadgett>
Status: CLOSED ERRATA QA Contact: Artyom <alukiano>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 3.3.0CC: amureini, dfediuck, iheim, mavital, pstehlik, sbonazzo, scohen
Target Milestone: ---   
Target Release: 3.3.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: sla
Fixed In Version: ovirt-hosted-engine-ha-1.0.0-2.el6ev Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-21 16:51:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: SLA RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Greg Padgett 2013-12-09 15:47:03 UTC
(This bug is half of the issue previously reported in bug 1037641)

Description of problem:

The engine VM is currently migrated due to host health issues.  It would be better if it was migrated only for local maintenance, when the migration is more likely to succeed.


The two scenarios can be observed/tested as follows:

To trigger migration today, cause the host score on the host running the VM to be 800+ points less than the next best host (e.g. block the gateway).  After this fix, this score difference should cause the VM to shut down on the host and start up on the other host.

Today, entering local maintenance on a host will cause the VM to shut down.  After this fix, it will cause the VM to migrate.

Comment 1 Sandro Bonazzola 2013-12-10 15:15:39 UTC
patch merged upstream master.

Comment 3 Artyom 2013-12-23 13:54:01 UTC
Checked on ovirt-hosted-engine-ha-0.1.0-0.10.rc.el6ev.noarch
Vm try to migrate and failed, manual migration works fine and also virsh -c qemu+tls://host_ip/system works.
In vdsm.log I see error:
Traceback (most recent call last):
  File "/usr/share/vdsm/vm.py", line 324, in run
    self._startUnderlyingMigration()
  File "/usr/share/vdsm/vm.py", line 403, in _startUnderlyingMigration
    None, maxBandwidth)
  File "/usr/share/vdsm/vm.py", line 842, in f
    ret = attr(*args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/vdsm/libvirtconnection.py", line 76, in wrapper
    ret = f(*args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/libvirt.py", line 1178, in migrateToURI2
    if ret == -1: raise libvirtError ('virDomainMigrateToURI2() failed', dom=self)
libvirtError: operation failed: Failed to connect to remote libvirt URI qemu+tls://rose05.qa.lab.tlv.redhat.com/system

I see that this migration use host name and not host ip for virsh and this a problem.

Comment 5 Artyom 2013-12-27 07:21:47 UTC
Verified on ovirt-hosted-engine-ha-1.0.0-2.el6ev.noarch
Migration works fine, but have exception in agent.log, that relevant to this bug
https://bugzilla.redhat.com/show_bug.cgi?id=1043627

Comment 6 errata-xmlrpc 2014-01-21 16:51:59 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.

http://rhn.redhat.com/errata/RHEA-2014-0080.html