ZBT-1 to ZBT-2 -- z2m migration to z2m

edit 20251203 - as noted in a later post below, I continued to have inconsistent and weird behaviors, so I recently ended up doing a full reset and start from scratch on z2m+zbt2. So, migrators beware, things could get complicated.

edit 20251128 - I did end up with a few devices that stopped responding. Doing a ‘reconfigure & reinterview’ seemed to get them going, you will probably need to ‘wake’ them by pressing their pair button once for them to successfully configure and start working.

I went ahead and went through all of my zigbee devices to make sure they could successfully interview and tested each while monitoring logs to confirm they were passing messages.

I would recommend anyone migrating also double check that all devices interview successfully and generate their mqtt messages.


I received my zbt2 today, from ameridroid ordered within the first couple minutes of release.

The official documentation is @ https://support.nabucasa.com/hc/en-us/sections/29400567268253-Getting-started-with-Zigbee does not provide direct instructions for zbt-2 + z2m to z2m

this link shows support for z2m, but not step by step instructions.

I thought it was going to be painful and I guess I should have grabbed screens, but going by memory;

I did both a system backup and a z2m backup (z2m settings/tools).

I plugged my zbt-2 in to an open usb, with my existing zbt-1 still active, I went to settings > device and the zbt-2 was already discovered. I added it and started the onboard dialog, which I knew would want to use the default zigbee home automation mode.

I follow the dialog, selected zigbee, choosing the manual path, the zigbee firmware installed with no issues and prompted for a backup, which I then cancelled out of.

Following the FAQ link above, I found and stored both the zbt1 and zbt2 hardware info to a text file.

I stopped ztm, in the settings > addon > z2m > configuration > serial UI, I pasted the zbt2 device path and bitrate into the z2m configuration page. And ignored the zbt2 discovery.

Restarted z2m, and monitored the logs to see if any errors, did not see any, and m2q messages started flowing normally.

I started checking various devices and so far all have been working.

I did not have to follow the IEEE action @ FAQ | Zigbee2MQTT and Copying the ieee address of an adapter | Zigbee2MQTT which advises to copy the ieee device from the zbt1 to the zbt2 which I did not wish to do, so I tried it and it worked without it.

My zigbee network consists of 35 devices, all of them ikea except for some 3rd reality nightlights.

My devices did not appear to need the ieee changed, but of course YMMV depending on your devices.

After some time, I stopped z2m (probably unnecessary) and unplugged the zbt1 leaving only the zbt2 (and my skyconnect matter mode unmodified), then restarted z2m and disabled the now removed zbt1 device in the ha settings > devices > zbt.

I wanted to post my experience for others that receive their zbt2 in the coming days.

TLDR:
While I did a backup via z2m, I did not need to restore any data.
I did not need to copy the zbt1 IEEE to the new zbt2.
I updated the zbt2 device path and baud rate and started z2m.

FWIW, the onboarding migration with ZWA2 was a much smoother experience and I did not have to leave the discover dialog. I am sure the default zwa would have have been similar, but using m2q to m2q was a bit less smooth.

edit:
I noticed one of my vallhorns stopped working, but everything else seemed to be fine, so far.

I tried re-pairing it, and it would interview then leave, some error about the database.

I went exploring and found and removed the device from the z2m configuration yaml (after stopping z2m first), then restarted z2m and paired again successfully.

3 Likes

I did basically the same procedure, but did need to clone the IEEE address. A few Aqara devices were NOT happy post migration until I cloned the coordinator’s address. I also took a Proxmox snapshot of my HAOS VM in case things went really south.

1 Like

Mind telling how to change the IEEE address ?
I’m using Z2M with HA addon.
Maybe I need to look in the configuration folder of HA ?

I haven’t had to use them, so can’t say how it will go.

1 Like

I understand that migrations depend on which coordinator/adapter one is migrating “from”, so just a recommendation, but may want to tweak the title to something like “ZBT-1 to ZBT-2 migration for z2m” or make some statement early on that this guide is for migrating a ZBT-1 to ZBT-2 for z2m.

1 Like

I think that even though you are using Zigbee2MQTT (a.k.a. Z2M) with Home Assistant it is important to understand that Zigbee2MQTT is a separate application plus remember that they have their own community too, and therefor it probaby a good idea to refer to their guides there too as those probably have more knowledge specific to Zigbee2MQTT needed for radio type adapter migrations. See for example:

Also note that the linked Z2M community guide in turn contains many more links to other references.

More references:

In summery I think that guides for migratiing between radios in Zigbee2MQTT belongs in the Z2M community forum instead → Koenkk/zigbee2mqtt · Discussions · GitHub

Or perhaps better yet, consider updating their website FAQs and/or adding articles there too in order to extend the official Zigbee2mqtt documentation → GitHub - Koenkk/zigbee2mqtt.io: 📘 Zigbee2mqtt documentation

1 Like

I’m confused about which title you refer to, and who?

This thread is about z2m to z2m migration.

If you mean one of the linked guides, I don’t have any control over those, but be more specific which one, and maybe someone who does can help make it clearer.

edit: I added ZBT-1 to ZBT-2 in the title, but I already did state I was migrating from zbt1 in the first post, but in any case, I not sure it matters that it was from zbt1 specifically, more important was the steps to get the zbt2 ZB firmware installed/updated and configured.

I am struggling with this migration myself. I have tried the instructions here and even cloned the ieee address, but I have instability in my network. No matter how I transfer to the new coordinator.

I am back on my ZBT-1 coordinator instance and it is once again rock solid. I am not sure if I did something wrong way back when I started my entire Z2M add-on or if this is just a me issue. I really don’t want to nuke the whole network (80+ devices), rebuild it, rebuild all of my groups, and then finally all of my automations.

How long did it take your networks to stabilize? I am having the most issues with my Inovelli switches.

Actually I did have continued weirdness and last night I finally around and just wiped and reset my entire zigbee network, starting from scratch with zbt2.

I made a copy of the configuaration yaml and db files, re-paired everything and made the zigbee device names the same. Double checked automations etc working.

I only have about 35 devices, it was minor pain but seems to be back to normal reliability.

The whole process of (z2m) migration has really left a lot to be desired.

Yeah. It actually has me considering going back to ZHA. Thanks for your confirmation.

Hello,
if it may help, I did the migration Z2M to Z2M last weekend. I am not coming from the ZBT1 but from the Sonoff -P, but I think the instruction should cover it.
I documented the procedure I followed on the French HACF forum and i put an english translation here.

On my side, it went quite smoothly, just a few devices that took some time to reconnect, but less than 10% (I have about 150 devices…)

I hope it gives you a good way to start.

4 Likes

@vdelab Huge thanx! You’re writeup was so easy to follow!

For others that might struggle with the IEEE;
I tried with both Powershell in Administrator mode and from Ubuntu 24.04 running as WSL, none worked. But after plugging into my Ubuntu server it all went without a hickup.

I write yesterday evening my old IEEE in the ZBT-2 and everything works. But now the entity ZBT2 firmware is unknown and the firmware shows me Gecko Bootloader 2.04.03. Is it possible that I lost the original firmware when writing to the IEEE and now I can no longer update the firmware in Home Assistant?

Maybe explain how or what tool/command you used to re-write the IEEE Address and the exact command and options selected. For example, if you use: universal-silabs-flasher --device /dev/ttyACM0 write-ieee --ieee 00124b0000000037, then I don’t think that would affect the firmware.
If for some reason you did corrupt the firmware, I would think you could reflash it.

In case any one is curious: I switched from ZBT-1 to ZBT-2 with z2m just now and it was a breeze.

  • I changed the ieee address of the ZBT-2 to match the address of the ZBT-1
  • I stopped Z2M
  • I changed the serial address in the Z2M addon settings and set the baudrate to 460800
  • started Z2M again, everything works fine
2 Likes

A slightly different way that worked for me without the need to manually change the IEEE

ZBT-1 to ZBT-2 in Zigbee2MQTT (Using ZHA to clone)

  • make a backup of home assistant and the Zigbee2MQTT folder just in case

  • Stop the Zigbee2MQTT add-on and leave the ZBT-1 plugged in

  • activate the ZigBee Home Automation Integration (ZHA) and use the ZBT-1 as the Coordinator.

  • Choose advanced and let it use the saved network on the ZBT-1.

  • A few devices should pop up but you don’t need to wait for all of them.

  • click on migrate to new adapter (the ZBT-2 should be plugged in by now) and choose the ZBT-2.

  • I used the automatic migration option.

  • ZHA will clone the ZBT-1 onto the ZBT-2.

  • Once it is done unplug the ZBT-1 and deactivate or delete ZHA again to free the adapter for Zigbee2MQTT.

  • go into the file explorer and delete the coordinator_backup.json from the Zigbee2MQTT folder. (Zigbee2MQTT will then use the saved configuration on the ZBT-2 itself)

  • Change the Configuration in Zigbee2MQTT to the one for the ZBT-2. (configuration.yaml or in the ui)

->adapter: ember
baudrate: 460800
port: (you can find it in Settings-> System-> Devices)

  • after that you should be able to start Zigbee2MQTT again and all devices should be there.
1 Like