Categories:

Finding an appropriate graphics card, the right supporting server hardware and actually getting the graphic card to output to a monitor took a couple of weeks. But, the actual setting changes required to get it all to work were very easy and minimal (once I figured it all out). The same cannot be said for passing through a keyboard and mouse to a VM. The experience is actually quite opposite.

I had a spare Logitech Unifying mouse & keyboard + USB receiver that I decided to try to use as my HID (Human Interface Device) for my Gaming VM test. Here is a great write up that I found to use as my guide. My googling turned up suggestions that it might be infinitely easier to passthrough a USB hub because the PowerEdge or ESXi will not try to claim it. But, I don’t have one laying around and “easy” isn’t very interesting. The (still quiet) server is less than two feet away from my desk at the moment, so this method should work fine for my test.

Configuring USB HID Passthrough

Following are the steps that I followed to get my Logitech Unifying receiver passed through to my Windows VM:

  1. On the ESXi host go to Actions -> Services -> Enable Secure Shell (SSH)
  2. SSH into ESXi
  3. Type lsusb and press enter to execute the command
  4. Get the ID of the USB device (046d:c52b for me):
  5. Type vi /etc/vmware/config and press enter to edit the config file
    1. Press the letter i to enter insert mode
    2. Arrow down to the line below the last line of text
    3. Add the following to the next available line in the file:
      • usb.quirks.device0 = "0x046d:0xc52b allow"
    4. Press the “Esc” key on the keyboard
    5. type :w then press enter
    6. type :q then press enter
  6. Type vi /bootbank/boot.cfg and press enter to edit the config file
    1. Press the letter i to enter insert mode
    2. Arrow up to the line that starts with kernelopt, go to the end and press the spacebar
    3. Add the following to the end of the line after the space:
      • CONFIG./USB/quirks=0x046d:0xc52b::0xffff:UQ_KBD_IGNORE
    4. Press the “Esc” key on the keyboard
    5. type :w then press enter
    6. type :q then press enter
  7. Reboot ESXi
  8. Select the VM -> Edit Settings -> VM Options -> Advanced -> Edit Configuration -> Add parameter: Key = usb.generic.allowHID Value = TRUE
  9. Click Add parameter again: Key = usb.quirks.device0 Value = 0x046d:0xc52b allow
  10. Click OK
  11. Select Virtual Hardware -> Add other device -> USB Device
  12. Click Save
  13. Power On your VM. A full reboot of ESXi may be required. The mouse didn’t work at first. Then, I accidentally unplugged my server and everything worked after it was all rebooted.

Summary

While I don’t intend to use HID passthrough for my kid’s Gaming VMs, I can see how using the same make/model of HIDs might not work. I suspect if I plug in another Logitech Unifying receiver (which I do have, and might try for fun), it would have the same identifiers and ESXi wouldn’t know which one to pass to which VM.

Regardless, I now have a fully functional Gaming VM! Time to see what can and can’t be done!

Tags:

3 Responses

    • I had one of the mouse & keyboard combos that have a transmitter and I was able to pass the transmitter through. My server doesn’t have bluetooth. I don’t know for sure, but I can understand how Bluetooth might not be recognized as a HID because Bluetooth could transfer more than just mouse & keyboard information.

Leave a Reply

Your email address will not be published.