Skip to content

Commit 33e4f26

Browse files
committed
Use shutdown API to stop domain
Stop domain gracefully using the shutdown API. Signed-off-by: Flavio Castelli <[email protected]>
1 parent b14a80e commit 33e4f26

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

kvm.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ func (d *Driver) Stop() error {
437437
}
438438

439439
if s != state.Stopped {
440-
err := d.VM.DestroyFlags(libvirt.DOMAIN_DESTROY_GRACEFUL)
440+
err := d.VM.Shutdown()
441441
if err != nil {
442442
log.Warnf("Failed to gracefully shutdown VM")
443443
return err

0 commit comments

Comments
 (0)