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.

[6.12.8] USB device deselected from VM passthrough after server reboot

Featured Replies

Hi all,

 

I have a problem with the USB passthrough to a Linux VM (Home Assistant). My Bluetooth dongle, a Cambridge Silicon adapter, is always being unselected in the VM configuration after I do a reboot of the server. I have a Sonoff Zigbee dongle which works just fine. It is selected via the same procedure.

I have already tried switching the USB port and connecting the Bluetooth dongle to the same controller as the Zigbee dongle. Unfortunately, the result remains unchanged.

The device is listed as "(HCI mode"). Does this play any role in this case?
Moreover, I have noticed that once I apply the settings in the VM config and then refresh the page, both main and optional are checked in the menu, altough I only selected the device only inside the left column in the first place:

 

unraid-vm-usb.thumb.png.9161f394a95b2e9ff65bebb8dac4d196.png

 

Any idea why this is happening?
Appreciate your help!

 

Kind regards

Edited by Gemuesefraumann

  • Gemuesefraumann changed the title to [6.12.8] USB device deselected from VM passthrough after server reboot
  • Community Expert
23 hours ago, Gemuesefraumann said:

Hi all,

 

I have a problem with the USB passthrough to a Linux VM (Home Assistant). My Bluetooth dongle, a Cambridge Silicon adapter, is always being unselected in the VM configuration after I do a reboot of the server. I have a Sonoff Zigbee dongle which works just fine. It is selected via the same procedure.

I have already tried switching the USB port and connecting the Bluetooth dongle to the same controller as the Zigbee dongle. Unfortunately, the result remains unchanged.

The device is listed as "(HCI mode"). Does this play any role in this case?
Moreover, I have noticed that once I apply the settings in the VM config and then refresh the page, both main and optional are checked in the menu, altough I only selected the device only inside the left column in the first place:

 

unraid-vm-usb.thumb.png.9161f394a95b2e9ff65bebb8dac4d196.png

 

Any idea why this is happening?
Appreciate your help!

 

Kind regards

Could you post diagnostics

  • Author

Maybe I should add: The dongle is working flawlessly in my Home Assistant VM once I reassign the adapter in the VM configuration after system reboot. The issue is that it always reverts back and removes the dongle from the selected devices once the system reboots or the array is restarted.

 

Both my Zigbee Dongle as well as a USB soundcard I tried the other day are being applied permanently and presist in the VM configuration even after reboot. The issue thus appears to be somehow specific to the bluetooth dongle. I just don't get why the selection of that device resets all the time. Since it does also occur after restarting the array, I don't think that it is related to something like the USB power management, boot order or something.

 

Do you think excluding the device from the host is the solution here?

 

 

  • Community Expert
10 hours ago, Gemuesefraumann said:

Maybe I should add: The dongle is working flawlessly in my Home Assistant VM once I reassign the adapter in the VM configuration after system reboot. The issue is that it always reverts back and removes the dongle from the selected devices once the system reboots or the array is restarted.

 

Both my Zigbee Dongle as well as a USB soundcard I tried the other day are being applied permanently and presist in the VM configuration even after reboot. The issue thus appears to be somehow specific to the bluetooth dongle. I just don't get why the selection of that device resets all the time. Since it does also occur after restarting the array, I don't think that it is related to something like the USB power management, boot order or something.

 

Do you think excluding the device from the host is the solution here?

 

 

So the USB device is remove from the VM in the template?

 

How do you re-add the device to the xml. You could try using my USB Manager and see if that fixes you issue. Not sure why the template option does not work. If you can provide screen shots before and after, also a new syslog just after you start the VM.

 

Example settings below for a USB Bluetooth device. If you use this method you dont need to have in VM template.

 

image.png

 

image.png

  • Author
On 3/23/2024 at 8:18 AM, SimonF said:

So the USB device is remove from the VM in the template?

The device is still visible but unselected in the GUI after reboot or array restart.

There is also a strange phenomenon with that editor that always applies the "optional" tag once I save and refresh the page.

 

Here is what the XML looks like:

    <hostdev mode='subsystem' type='usb' managed='no'>
      <source startupPolicy='optional'>
        <vendor id='0x0a12'/>
        <product id='0x0001'/>
        <address bus='1' device='2'/>
      </source>
      <alias name='hostdev1'/>
      <address type='usb' bus='0' port='3'/>
    </hostdev>

 

The optional-policy seems to apply the following rule (accoding to this post):

 

Quote

optional | drop if missing at any start attempt

 

No idea if this is relevant for this issue.

 

 ---

In the meantime I also installed your USB Manage and it looks like that has solved the issue. I have attached my USB devices to the VM only through the Manager now and the connection is correctly being established even after reboot.

 

Thank you very much for your kind support and the development of that great tool! :)

 

 

 

Edited by Gemuesefraumann

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.