Story of the disappearing usb zwave and zigbee dongles [Solved]

I recently added a usb zwave and conbee II usb dongles to my server as I was moving my devices away from my smartthings setup.

I suspect my HA setup is a common one. I have a linux server that hosts virtualbox instances and HA is installed on its own virtualbox instance.

Within the first few days I noticed a problem, my zwave network would stop working, usually after about 5 hours or so of bootup. After this happened a few times I actually noticed my zwave usb device was missing in my HA virtual host, hence the outage.

I did some googling and suspected my linux O/S may of been putting the usb device to sleep due to inactivity, penny dropped at this point because my zwave network stopped working during the night and when everyone was at work, thus zwave network was pretty much inactive… perhaps because my HA instance runs in virtualbox maybe virtualbox was messing things up when the usb zwave came out of sleep.

So I edited on my virtualbox host the file /etc/default/grub and changed the following line:

from:
GRUB_CMDLINE_LINUX_DEFAULT="quiet"
to:
GRUB_CMDLINE_LINUX_DEFAULT="quiet usbcore.autosuspend=-1"

then ran grub-update

Just for good measure I did the same on my HA virtual machine too.

Fingers crossed its never happened again.

3 Likes

omg!!! Ok so when I made this fix the system went from loosing the usb sticks EVERY night and EVERY day while at work to working rock solid for the best part of a week… well it happened again last night so I guess this fix does not work.

TBH I’m just going to skirt round this issue. I’m now using usbip to share the usb sticks on the bare metal server and attach them in my HA virtual machine. This is something I was considering doing anyway because in my experience I’ve found zwave to be rubbish at meshing, all the devices simply want to connect direct to my zwave controller so my controller needs to be in the centre of the house… we, the usb sticks do at least. My long term plans are to attach the zwave and zigbee sticks to a raspberry pi that I will place in the centre of the house then use usbip to share them back to the HA virtual machine.

If anyone is interested in usbip, here is a pretty handy guide