fix: resolve Guest Server API going offline and default to slirp networking on Podman#783
Open
Vikyek wants to merge 1 commit into
Open
fix: resolve Guest Server API going offline and default to slirp networking on Podman#783Vikyek wants to merge 1 commit into
Vikyek wants to merge 1 commit into
Conversation
…orking on Podman
This PR addresses issues causing the WinBoat Guest Server API to periodically go offline and fail silently, as
well as fixing a Vue Ref unwrapping bug that incorrectly logged and handled offline states in the frontend.
#### Changes
1. Default to slirp networking for Podman containers ( src/renderer/data/podman.ts )
• Issue: The default networking mode on Podman was configured to user mode. This utilizes the passt
daemon inside the container for port forwarding. In rootless Podman environments, the passt daemon was
crashing under CPU load/connections, disconnecting /tmp/passt_1.socket and leaving the Windows VM
completely without network access (taking the Guest Server API offline). It also caused QEMU to loop/spin,
consuming ~315% CPU on the host.
• Fix: Switched the default networking configuration for Podman to slirp . This uses QEMU's internal user-
mode networking and hostfwd rules directly, eliminating the dependency on passt and preventing crashes.
Host CPU utilization drops from 315% to a normal 63% .
2. Fix Vue Ref unwrapping bugs ( src/renderer/lib/winboat.ts )
• Issue 1: The logger checked this.isOnline (which is a Vue Ref<boolean> wrapper object) in a ternary
expression: this.isOnline ? "online" : "offline" . Because the Ref wrapper object is always truthy, this
always evaluated to "online" , which flooded log files with "went online" messages even during offline
transitions.
• Issue 2: The app launch guard checked !this.isOnline , which also incorrectly evaluated to false ,
causing app launches to proceed when the VM was offline and fail silently downstream rather than displaying
a clear error.
• Fix: Appended .value to both unwrapped Ref boolean checks ( this.isOnline.value ).
Contributor
|
@Vikyek The first issue should already be fixed since the dockur/windows image has been updated to v5.15. If your Podman+Passt issue still exists in v5.15, please make an issue in that repo. |
Collaborator
|
My view is that of kroese's. Happy to merge the 2nd fix. If the podman change is removed I can merge as-is. Not saying we won't make the change, if you feel strongly that it's still needed post the 5.1.5 uprev, then raise another PR and we can discuss that one there. Tibix or Levev would likely need to look into that one. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR addresses issues causing the WinBoat Guest Server API to periodically go offline and fail silently, as
well as fixing a Vue Ref unwrapping bug that incorrectly logged and handled offline states in the frontend.
Changes
• Issue: The default networking mode on Podman was configured to user mode. This utilizes the passt
daemon inside the container for port forwarding. In rootless Podman environments, the passt daemon was
crashing under CPU load/connections, disconnecting /tmp/passt_1.socket and leaving the Windows VM
completely without network access (taking the Guest Server API offline). It also caused QEMU to loop/spin,
consuming ~315% CPU on the host.
• Fix: Switched the default networking configuration for Podman to slirp . This uses QEMU's internal user-
mode networking and hostfwd rules directly, eliminating the dependency on passt and preventing crashes.
Host CPU utilization drops from 315% to a normal 63% .
• Issue 1: The logger checked this.isOnline (which is a Vue Ref wrapper object) in a ternary
expression: this.isOnline ? "online" : "offline" . Because the Ref wrapper object is always truthy, this
always evaluated to "online" , which flooded log files with "went online" messages even during offline
transitions.
• Issue 2: The app launch guard checked !this.isOnline , which also incorrectly evaluated to false ,
causing app launches to proceed when the VM was offline and fail silently downstream rather than displaying
a clear error.
• Fix: Appended .value to both unwrapped Ref boolean checks ( this.isOnline.value ).