Skip to content

Commit 1cfb6aa

Browse files
committed
xenmgr: Add xl trigger power to HVM shutdown
The QEMU ACPI hvm-shutdown and hvm-power-button xenstore entries don't always work. On the QEMU side, it looks like the IRQ is raised and the ACPI_SLP_BIT is cleared, but the guest doesn't shutdown. `xl shutdown -F -w` just hangs. Manually running `xl trigger DomU power` after that seems to trigger the shutdown, so just have xenmgr make that invocation. Signed-off-by: Jason Andryuk <jandryuk@gmail.com>
1 parent 2e88dcf commit 1cfb6aa

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

  • xenmgr/XenMgr/Connect

xenmgr/XenMgr/Connect/Xl.hs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,7 @@ shutdown uuid =
185185
case exitCode of
186186
ExitSuccess -> return ()
187187
_ -> do xsWrite ("/local/domain/" ++ domid ++ "/control/hvm-shutdown") "poweroff"
188+
_ <- system ("xl trigger " ++ domid ++ " power")
188189
_ <- system ("xl shutdown -F -w " ++ domid)
189190
return ()
190191
Nothing -> do system ("xl shutdown -c -w " ++ domid)

0 commit comments

Comments
 (0)