Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Using a KVM switch with an unraid virtual machine

Featured Replies

Hi, I am having a problem trying to set up a KVM switch (the other KVM that is used to switch keyboards and monitors, not the KVM virtualization software more likely to be mentioned on this forum) with an unraid virtual machine.  I have several computers that I want to be able to switch between rather than have 3-4 separate keyboards, monitors etc.  I have linux and windows virtual machines within unraid i would like to be able to plug into the KVM system.  The unraid virtual machine works fine when I first boot it.  The issue is when I switch to another computer and then come back to the original VM monitor, I cannot get the keyboard or mouse input working again.  I assume that the USB devices I passed through to the VM lost contact when I switched away on the KVM switcher, and never got reconnected/passed through when i switched back to the VM. 

 

Is there any sort of plugin or setting that will force a virtual machine to pass back through the same keyboard mouse after they have been briefly disconnected while the virtual machine is still running?

  • Community Expert

My usbip-gui plugin may help you. You dont need to use the USBIP bit as I have added other USB functions into it. If the system detects the USB device effectively being unplugged and plugged in then it will auto connect.

 

image.thumb.png.df6f509122aeffad6567115cf80a807d.png

  • Author

Super! Many thanks! I will give it a try.  I was hoping someone might have built a plugin that addressed this issue.

 

  • 2 weeks later...
  • Author

Hi, I just wanted to follow up again.    I installed the usbip-gui plugin which said it needed usbip to run, but i did not see that as an installable community plugin.  I found 

and then added the text to the /etc/libvirt/hooks/qemu configuration file and enabled USBIP, but even after doing that I get at the top "Following are missing or not loaded: usbip_host module vhci_hcd module" and then below on USB page under USBIP setting and load kernel modules it also says "The usbipd command missing or usbip_host module not loaded..", "The usbip_host module does not exist..", and "The vhci_hcd module does not exist.." 

 

I clearly am missing a step and something is not installed.   I saw something mentioned in the comments about "The module is the kernel module usbip_host, I think initially limetech only included vhci_hcd and usbip_core. I guess it could be sideloaded with the new process but ideally it should be baked into standard modules if the other two are there already." which implied Limetech might have left something out?  Just wanted to know how do I go about installing what needs to be installed.  Is there some reference or page you could point me to?

 

Thanks for your help

  • Community Expert
32 minutes ago, WorldTraveller said:

which implied Limetech might have left something out?

The plugin installs the USBIP components if required, but is only supported on 6.9.

 

But I dont think you need the USBIP parts for your requirements,

 

You can turn them off in the USB settings page. You may need to change Enable USBIP to see the other parts, but the load kernel modules should be No and Run Daemon should be disabled. Then change Enable USBIP back to disabled and those messages should be hidden.

 

image.thumb.png.1d2b2309625cdd42271cf50e5e0de1ea.png

 

  • 9 months later...

I use USBIP, nice program.

Me too, with my KVM hardware, I wanted to automatic plug USB & Mouse whenb I switch between different VMs.

Any solution to automoatic assign 1 USB Keyboard & Mouse ?

Thanks ;)

  • Community Expert
1 hour ago, PicPoc said:

I use USBIP, nice program.

Me too, with my KVM hardware, I wanted to automatic plug USB & Mouse whenb I switch between different VMs.

Any solution to automoatic assign 1 USB Keyboard & Mouse ?

Thanks ;)

Do you have a separate usb connection for K&M for each VM.

You can create a port mapping to allocate the port to each VM on my plugin. Port will be auto connected when a device is connected.

 

image.thumb.png.e2925bbf7f1fd1ecdd80387b36851c7c.png

image.thumb.png.a903cd07986da9576dfffd963cabd1bc.png

  • 2 weeks later...

I'm in the same boat as others above - need to use my physical KVM switch to move between unraid VMs with my single keyboard and mouse.  As other have said, when the kvm switches to a different unraid VM, things lock up.  Right now I'm just trying to switch between my laptop and a single unraid VM.  So I have mapped the USB devices for mouse and kbd to that vm.  When I first save the config, it works great.  I switch the physical KVM to my laptop, and that works great.  I switch back to the VM and the KBD and Mouse are dead.  I have to unmap them and remap them in unraid control panel to get them to work again.

 

I'll try the suggested solution to see if that works.  If not, I'm eager to work with someone to figure out whats going on & what to do about it.

 

 

  • Community Expert
6 minutes ago, M2Pilot said:

KBD and Mouse are dead.

The reason is when usb devices get unplugged and replugged the dev number will change. My plugin detect the device being commected and will map the ports to the VM. You need to remove the mappings in the vm template.

Alas, using the USBIP plugin does not immediately solve the problem.  But does seem to give a hint what the problem is.  See the attached screen shot.  Note the error reported for both the keyboard and mouse.  Who might I report this to??

 

 

Screenshot from 2022-01-03 14-15-26.png

  • Community Expert

If you hover over the triangle it will tell you the error. I suspect it already in use and was mapped outside the USB Manager plugin.

Edited by SimonF

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.