Skip to content

v0.2.4

Choose a tag to compare

@github-actions github-actions released this 13 Sep 19:03
· 16 commits to main since this release

On Windows, stopping the engine took ten seconds and then reported an error, and on slower machines it took minutes. An up sent during that time said the engine was already running while it was still shutting down. This release fixes both. Nothing else has changed since v0.2.3.

The guest could not power off on x86

libkrun's x86 machine has no ACPI, so when the guest asked to power off, the kernel printed reboot: Power off not available: System halted instead and halted every CPU. On Linux, KVM reports that halt to libkrun and the VM ends. On Windows, libkrun's WHP backend keeps waiting on a halted CPU, so every graceful stop waited out its full timeout and then the worker was killed.

On x86 the guest now reboots instead. The reset goes through the i8042 controller, which libkrun treats as a VM exit on both hypervisors, and libkrun's own init shuts down the same way. arm64 still powers off through PSCI.

Measured on Windows 11 (i9-13900K, WHP):

v0.2.3 v0.2.4
nebula down 10 s, then stop failed: VM entered Failed state (exit 1) 0.5 s, exit 0
nebulad gone 14 s after the command started before down returns

A forced stop no longer runs twice

Killing the krun worker makes it exit non-zero, and that reads as Failed. The stop path waited for Stopped, so it failed immediately. The shutdown then treated the VM as still running and repeated the whole graceful attempt, this time against an agent that no longer existed and with no read timeout. Now Failed also counts as stopped, and the shutdown request to the agent is capped at 5 seconds.

down and up agree about when the engine is gone

  • nebula down returns only after the daemon has exited, not just after it replies. Before, a caller that started the engine again in that gap found the old daemon still holding the socket, the ports and the VM.
  • nebula up waits for a daemon that is shutting down instead of reporting it as already running.
  • nebula status shows nebula: stopping (daemon shutting down) during a stop.
  • While a stop is in progress, the daemon answers every request with nebulad is shutting down. It no longer ends its listener early, which also started a second shutdown that exited the process in the middle of the first.

Embedders: new guest images come with this release, so install-image applies after upgrading. Older CLIs keep working against the new daemon; during a stop they get an ordinary error message.