Troubleshooting Zigbee stick

I’m running home assistant in an iocage jail on FreeNAS. My motheboard died, and I ended up moving my drives to a new system. (not a great start)

All seems to be well, except my Conbee II Zigbee stick just won’t seem to work. I’ve removed and re-added the zha integration about a thousand times, and it has no problem seeing the stick or adding the integration, but I never get any devices. That includes, I never get any device to add other devices from. The integration is there, but there is no way to to anything with it.

Any ideas on where to start troubleshooting?

Here’s the relevant section from the logs. Unfortunately, this doesn’t tell me a lot.

2020-10-27 21:59:44 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-10-27 21:59:44 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry n/a, s/n: n/a for zha
Traceback (most recent call last):
  File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/config_entries.py", line 231, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/components/zha/__init__.py", line 100, in async_setup_entry
    await zha_gateway.async_initialize()
  File "/srv/homeassistant/lib/python3.7/site-packages/homeassistant/components/zha/core/gateway.py", line 148, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/srv/homeassistant/lib/python3.7/site-packages/zigpy/application.py", line 68, in new
    await app.startup(auto_form)
  File "/srv/homeassistant/lib/python3.7/site-packages/zigpy_deconz/zigbee/application.py", line 80, in startup
    await self.form_network()
  File "/srv/homeassistant/lib/python3.7/site-packages/zigpy_deconz/zigbee/application.py", line 151, in form_network
    raise Exception("Could not form network.")
Exception: Could not form network.

To further clarify, there is usually a ‘Zigbee Coordinator’ device, and it is simply missing.

I’ve found multiple references to the errors in that log, but they are all on linux systems (I’m on FreeNAS, which is FreeBSD, so it’s similar) and they all seem to refer to a modem service on either the host of in a VM having control of the usb-serial device.

I’ve checked, and I don’t appear to ahve any modem related services running on the host or in the jail, and the only other service I could find using USB-serial is for my UPS, and I went ahead and disabled that service to see if it made a difference. It did not.

Wondering how else to identify what is tying up a serial device…

Well, I fixed it. Or at least, worked around it.

While the device is a USB 2.0 device, moving it to a 3.0 port seemed to resolve the issue. That, or moving it was coincidental and what fixed it was 4,385th time I reinstalled the zha integration.

Either way, seems to be up, and surviving reboots.