Change in vdsm[master]: migration added migrateChangeParams verb

tjelinek at redhat.com tjelinek at redhat.com
Fri Oct 9 11:55:14 UTC 2015


Tomas Jelinek has posted comments on this change.

Change subject: migration added migrateChangeParams verb
......................................................................


Patch Set 3:

(1 comment)

https://gerrit.ovirt.org/#/c/46934/3/vdsm/virt/vm.py
File vdsm/virt/vm.py:

Line 1546:         finally:
Line 1547:             self._guestCpuLock.release()
Line 1548: 
Line 1549:     def migrateChangeParams(self, params):
Line 1550:         self._acquireCpuLockWithTimeout()
> Please note that this is still a subject of investigation if really needed 
so after a longer investigation the thing is this:
- libvirt does the proper locking of the monitor commands (including this one) so we should not need to lock to avoid races
- but VDSM does locking by itself here (I guess because of historical reasons) which avoids some races inside the VDSM code. This races are the ones like "race between migrate change params and cancel migration".
- it does not handle races like "cancel migration and the migration finished by itself"

Long story short, this locking is handling a subset of the possible races, the rest is handled inside libvirt. For consistency reasons I'm adding the same locking also here and leaving the question if the locking should be handled only by libvirt or not to the future.
Line 1551:         try:
Line 1552:             if self._migrationSourceThread.hibernating:
Line 1553:                 self.log.warning('can not change migration parameters, vm is hibernating')
Line 1554:                 return response.error('migNotInProgress')


-- 
To view, visit https://gerrit.ovirt.org/46934
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I52219c0e1f7d619dd30441dd4c70bd401f91e56d
Gerrit-PatchSet: 3
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Tomas Jelinek <tjelinek at redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani at redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Tomas Jelinek <tjelinek at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-HasComments: Yes


More information about the vdsm-patches mailing list