2nd Home assistant does not find USB devices

Hello everyone,

I would like to run 2 homeassistant instances on nuc via VM;
1 for testing and 1 as real.
However, I now have 2 running, but when I start the first one my USB devices are recognized, but when I start the second one it does not see the USB devices!!! Can I solve this? If yes, how?

You can only ‘pass-through’ USB devices to one VM at a time. So when you change VM, you need to change the ‘pass-through’ settings of the used USB devices too.

Thank you for your reaction.

So if I understand correctly, this is not possible?

You can’t use the same USB device in 2 VM’s at the same time. So no, not possible.

Thank you very much for your response

Is there perhaps another solution to run 2 Home Assistant instances side by side?

Depends what USB devices you use, and what integrations.

For Zigbee, create a third VM, pass your dongle to that VM, run Zigbee2MQTT and Mosquitto on that VM.
For Z-Wave, you could do the same with either Z-Wave JS or Z-Wave JS UI
For rflink, you could ditch the USB-part and attach an ESP-01 to get the information

Thank you.

Is there a concise explanation somewhere, because this is going a bit too quickly for me. I test a lot and am already quite up to date, but this is still a bit too complicated!

What VM Manager are you using ? Obviously not Hyper-V since that does not support USB-passthrough.

And what dongles do you have ?

Oracle VM
Dongles
Schermafbeelding 2024-02-19 192527

USB devices can, by limitation defined the standard, only have one master.

What is being suggested here is to move the USB devices to other computers/devices/VMs, so they act as masters and then use the MQTT protocol to relay the events.
MQTT is a service that allow many slaves to connect to it and many master to also connect to it.

The problem with a MQTT setup and multiple HAs (masters) is that you might have to handle events caused by one HA on the other HA and vice-versa to have them in sync.