Attempt to cleanup failed migrations using a pidfile
authorHrvoje Ribicic <riba@google.com>
Mon, 8 Jun 2015 16:44:15 +0000 (16:44 +0000)
committerHrvoje Ribicic <riba@google.com>
Thu, 11 Jun 2015 14:23:17 +0000 (16:23 +0200)
commitd43c2d309d5d2b9829d2988e9b145be4b8a9de47
tree47c6e5944dd4341bc8c4d3da1cac2fe14238e684
parent7b8d7271acd8973b88d009117ad3e5d31d86755a
Attempt to cleanup failed migrations using a pidfile

In the case that a listening socat daemon was started but the migration
failed on the sending side, the daemon will stay in place and occupy
the migration port forever. This patch attempts to remedy this by
saving the PID of the daemon, and attempting to kill it when the next
migration is started, provided the command line roughly matches our
migration workflow.

Signed-off-by: Hrvoje Ribicic <riba@google.com>
Reviewed-by: Klaus Aehlig <aehlig@google.com>
lib/hypervisor/hv_xen.py
src/Ganeti/Constants.hs