Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GUI does not close with state HardStop #67

Closed
baude opened this issue Nov 1, 2023 · 2 comments
Closed

GUI does not close with state HardStop #67

baude opened this issue Nov 1, 2023 · 2 comments

Comments

@baude
Copy link
Collaborator

baude commented Nov 1, 2023

I believe we have a bug (possibly down in vz) where if you run with --gui and the required graphical elements (shown below), when a HardStop state change is requested, the GUI is not closed.

Observations:

  • the regular Stop state change does close the GUI
  • With HardStop, the machine vm is definitely shutting down

Doing something like:

/usr/local/bin/vfkit --bootloader efi,variable-store=/Users/brentbaude/efi-variable-store,create \
	--device virtio-blk,path=/Users/brentbaude/fedora_server.raw \
	--device virtio-net,nat,mac=52:54:00:70:2b:71 \
	--device virtio-rng --device virtio-input,keyboard \
	--device virtio-input,pointing \
	--device virtio-gpu,width=1920,height=1080 \
	--gui \
	--cpus 2 \
	--memory 4192 \
	--restful-uri tcp://localhost:8081

And observe the differences in behavior for the following restful calls:

brentbaude@Brents-Mac-mini vfkit % curl -X POST  -H 'Content-Type: application/json' -d '{"state": "Stop"}'  http://localhost:8081/vm/state
brentbaude@Brents-Mac-mini vfkit % curl -X POST  -H 'Content-Type: application/json' -d '{"state": "HardStop"}'  http://localhost:8081/vm/state
@cfergeau
Copy link
Collaborator

cfergeau commented Nov 10, 2023

This is a Code-Hex/vz issue. I've reported it in Code-Hex/vz#150 and https://github.com/cfergeau/vz/tree/hardstop-gui has a fix.
It can be tested in vfkit with go mod edit --replace=github.com/Code-Hex/vz/v3=github.com/cfergeau/vz/v3@hardstop-gui followed by a build.

@cfergeau
Copy link
Collaborator

The update to github.com/Code-Hex/vz 3.5.1 should fix this.

@github-project-automation github-project-automation bot moved this from Ready for review to Done in Project planning: crc Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

No branches or pull requests

2 participants