From 3af0330c9e76393836459afcdeba133052fde9d5 Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Wed, 19 Sep 2018 15:13:36 +0200 Subject: vm/vmm: make more robust after restarts Instances from the previous run can still be running, so always stop the previous instances before starting new ones. --- vm/vmm/vmm.go | 1 + 1 file changed, 1 insertion(+) diff --git a/vm/vmm/vmm.go b/vm/vmm/vmm.go index dcf417f17..97c83ffcf 100644 --- a/vm/vmm/vmm.go +++ b/vm/vmm/vmm.go @@ -115,6 +115,7 @@ func (pool *Pool) Create(workdir string, index int) (vmimpl.Instance, error) { stop: make(chan bool), diagnose: make(chan string), } + inst.vmctl("stop", inst.vmName, "-f", "-w") // in case it's still running from the previous run closeInst := inst defer func() { if closeInst != nil { -- cgit mrf-deployment