
Daniel P. Berrange wrote:
On Tue, Apr 21, 2015 at 03:47:34PM -0600, Jim Fehlig wrote:
Daniel P. Berrange wrote:
On Fri, Apr 17, 2015 at 03:36:22PM -0600, Jim Fehlig wrote:
+ VIR_FREE(priv->lockState); + if (virDomainLockProcessPause(driver->lockManager, vm, &priv->lockState) < 0) + VIR_WARN("Unable to release lease on %s", vm->def->name); + VIR_DEBUG("Preserving lock state '%s'", NULLSTR(priv->lockState));
I see a few calls to ProcessPause, but I'm not seeing any to ProcessResume, so I think you might have missed a few places needing hooks.
Currently I'm not using ProcessResume and instead calling ProcessStart with paused param set to false. ProcessStart is called in libxlDomainStart, which is called by all paths that start a domain, e.g. start, create, restore, migrate, etc. I was under the impression that ProcessResume is not needed if ProcessStart is called with paused=false.
For virtlockd it doesn't matter, but with the sanlock driver there is a tiny difference due to VIR_LOCK_MANAGER_NEW_STARTED being passed to the virLockManagerNew() method in the Start case.
Ah, I see. Thanks for the explanation. I'll send a V3 to call ProcessResume right after ProcessStart. I also noticed a small goto label bug that will be fixed in V3. Regards, Jim