Moving mouse with the mouse disabled has jetkvm keep trying to open /dev/hidg1 #303

Open
opened 2026-02-20 08:21:50 -05:00 by deekerman · 2 comments
Owner

Originally created by @nagisa on GitHub (May 31, 2025).

Originally assigned to: @ym on GitHub.

Version 0.3.9, although I see in master that the code still reads the same:

github.com/jetkvm/kvm@8d77d75294/internal/usbgadget/hid_mouse_absolute.go (L68-L74)

With USB being set to only enable the keyboard, but not the mouse, moving mouse over the window will still keep sending mouse events to jetkvm, jetkvm will try to open the device file for each mouse event and send an error back to the client along the lines of

{ code: -32603, data: "failed to open hidg1: open /dev/hidg1: no such file or directory", message: "Internal error" }

each time.

Not an experience breaking issue, but it does cause a greatly increased cpu time consumption when there are significant mouse events.

Originally created by @nagisa on GitHub (May 31, 2025). Originally assigned to: @ym on GitHub. Version 0.3.9, although I see in master that the code still reads the same: https://github.com/jetkvm/kvm/blob/8d77d752946a2d56224d89fc43a507898855afdf/internal/usbgadget/hid_mouse_absolute.go#L68-L74 With USB being set to only enable the keyboard, but not the mouse, moving mouse over the window will still keep sending mouse events to jetkvm, jetkvm will try to open the device file for each mouse event and send an error back to the client along the lines of ``` { code: -32603, data: "failed to open hidg1: open /dev/hidg1: no such file or directory", message: "Internal error" } ``` each time. Not an experience breaking issue, but it does cause a greatly increased cpu time consumption when there are significant mouse events.
Author
Owner

@nagisa commented on GitHub (May 31, 2025):

With 0.4.1 this error message also ends up in last.log:

2021-01-01T13:18:10Z ERR jetkvm jsonrpc Error calling RPC handler error="failed to open hidg1: open /dev/hidg1: no such file or directory" id=2130 method=absMouseReport params={"buttons":0,"x":24268,"y":27169}

Given that there is no log rotation, given a sufficiently long uninterrupted session its probably possible to end up exhausting all of the storage available on the device.

@nagisa commented on GitHub (May 31, 2025): With 0.4.1 this error message also ends up in `last.log`: ``` 2021-01-01T13:18:10Z ERR jetkvm jsonrpc Error calling RPC handler error="failed to open hidg1: open /dev/hidg1: no such file or directory" id=2130 method=absMouseReport params={"buttons":0,"x":24268,"y":27169} ``` Given that there is no log rotation, given a sufficiently long uninterrupted session its probably possible to end up exhausting all of the storage available on the device.
Author
Owner

@ambis commented on GitHub (Feb 4, 2026):

I ran into this too. And for context, I'm using a 4-way HDMI switch to control 4 servers. This combo does not support mouse well, so I have jetkvm set to Keyboard Only.

@ambis commented on GitHub (Feb 4, 2026): I ran into this too. And for context, I'm using a 4-way HDMI switch to control 4 servers. This combo does not support mouse well, so I have jetkvm set to Keyboard Only.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/kvm#303
No description provided.