Migrate z-wave to other device, can I still go back?

I’m currently running home assistant with an aeon labs z-wave stick on a raspberry pi. Because the raspberry pi can barely take the load, I want to change the host to a Nuc with a intel i3.

I already installed everything and it seems to be running without a problem, but the last step I have to do is move over the z-wave stick. I’ve already read in Z-Wave Configuration Migration that I should be able to do that without much of a problem if I copy over the zwcfg*.xml file, but am a bit scared to actually take the step.

I have about 40 z-wave devices paired and would not be happy if I would have to re-include them, even more, wouldn’t want the missus to get mad when things are not working now that she finally is used to it :wink:

so what I was wondering, is if everything fails, can I just put the z-wave stick back in the pi and would it all be up and running again? or is there something stored on the stick that would prevent me from going back?

Yesterday I switched from home assistant in a venv to hassio (so same pi but new hardware).

The only real issue I had was that the entity_id’s are now kept in the .storage folder, and that isn’t really meant to be touched by the user. But once I copied the registry files in there over, it came right up. I went back and forth a few times during the process without issue.

If I knew the proper way to transfer entity_ids (I thought they were still in zwcfg, I was wrong) I probably could have done it in one shot.

Yes, you can take your Z-wave stick and plug it into any other computer and even run different software and your network will be preserved. The included nodes are stored on the z-wave controller (the z-wave stick) not on the RPi. Just shutdown HASS cleanly prior to removing the stick. If something fails on the NUC then you should be able go back to the RPi without a problem.

The migration thread you linked is a bit out of date, as the entity registry has been in use since that was written, but the basic idea holds true. The usb_path and network_key are now stored in the .storage/core.config_entries file. So as already mentioned, just copy over the .storage directory to the NUC and the information HASS needs about the z-wave configuration will be migrated. This includes any customizations of the z-wave node names, plus the entity ids assocated with the z-wave devices. The zwcfg*.xml cache file is not as important as before, unless you hand-edited it for some device customization.

You’ll want to make sure the usb_path is the same on both systems, usually /dev/ttyACM0. If it is different, you’ll need to edit the .storage/core.config_entries file and update it. Otherwise, HASS will not find your z-wave controller when it starts up.

3 Likes

Thanks for your comments! That’s actually some very useful information you gave me there freshcoast.

My pi is running on a rather old version of home assistant (0.57.1), while the nuc is running on the latest version (0.82.1). Now I’m wondering how I should migrate… Will it do anything with the zwcfg*.xml file? I hope so, because all names I gave the devices are in there (I never edited it by hand by the way) .

In that case, you’ll definitely want the zwcfg*.xml file (I would copy it anyways regardless of the version you’re migrating from). 0.82.1 will upgrade your config and import the z-wave settings from configuration.yaml into the .storage location. It will then generate the persistent entity IDs based on the node names that are set in the zwcfg*.xml file.

After 0.82.1 is running, the zwave entry in configuration.yaml is no longer necessary and you can actually remove it if you want.

If you end up with some entity naming problems, you can always customize the names through the GUI, or manually edit the config files. All that is discussed here: What is the preferred way to rename z-wave entities?

What about the network_key for secure connections? Where do you specify that in the UI?

If you use the Z-Wave Integration to set up Z-Wave for the first time, it should be an option you can set in the configuration dialog. If you leave the network key blank, HASS will generate one for you.

If you already had Z-Wave configured by configuration.yaml in an older version of HASS and upgraded recently (can’t remember exactly which version), HASS will import the configuration into the new location. If you had a network key set, it will continue to use the same one. If you didn’t have a network key set, I don’t think it will create one for you. Once these settings are imported they aren’t read from configuration.yaml anymore.

You can look at the file .storage/core.config_entries to see if you have a network key set. If you don’t, you’ll have to manually edit the file and add one. The Z-Wave settings are not visible nor are they editable in the UI.

1 Like

Hi freshcoast
I want to move my Home Assistant from a Raspberry Pi 3 using Z-Wave to an Intel NUC.
I have just built an Intel NUC8i3BEH using this guide

Everything seems to have gone fine until I get to the moving the Z-Wave Stick over to the NUC.
I made sure that both versions of Home Assistant were the same on the Pi and the NUC ie 0.103.6

My steps then were:

  1. Install the Samba ADD-ON on the NUC
  2. Create a full snapshot of the Hass.io instance on the Raspberry Pi
  3. Copy the Snapshot from the Pi backup folder to the backup folder on the NUC
  4. Shutdown the Pi & remove power from it
  5. Remove the Z-Wave Stick and plug it into the NUC
  6. Load the Snapshot from the Pi into the NUC as below. I used the Restore Select option as both were running 0.103.6
    The screen dump is from the NUC

However nothing seem to work except the Add-ONs. It loaded the configurator add-on in addition to the SAMBA

I am lost from here.

I have moved the Z-Wave stick back to the Pi until I get some more knowledge.

My guess is it’s something to do with the nuc recognising the Z-Wave stick after reading you words here but as it’s over a year old I thought I would seek advice before proceeding much further.
Is this still Valid?

Any advice gratefully received.

Regards

Update 17:00hrs 13/01/20

After a bit more research I read that I maybe should have checked the Home Assistant Box to do the restore.

So I tried again

I follow the same steps as above and all the config files came across.
However I could not seem to see my Z-Wave stick.

If I did an lsusb from the console this is what I saw
rontaylor@nuc-1:~$ lsusb
Bus 002 Device 003: ID 2109:0812 VIA Labs, Inc. VL812 Hub
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 008: ID 04d9:1503 Holtek Semiconductor, Inc. Keyboard
Bus 001 Device 007: ID 04d9:0499 Holtek Semiconductor, Inc. Optical Mouse
Bus 001 Device 006: ID 2109:2812 VIA Labs, Inc. VL812 Hub
Bus 001 Device 011: ID 0658:0200 Sigma Designs, Inc.
Bus 001 Device 003: ID 8087:0aaa Intel Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Looking for the mount point that HA is look for…
rontaylor@nuc-1:~$ ls /dev/ttyA*
/dev/ttyACM0

This seems to be the correct mount.

However none of my Z-Wave stuff seem to work.
My security cameras displayed their substreams and other non Z-Wave seem to work but…

Lost!
help!

I’m in similar situation.

I made a snapshot from my Raspberry Pi installation.
Installed Hassio on laptop running Ubuntu 18.04 LTS Desktop. Laptop is 2.1 GHZ, 3GB ram, SSD/HDD.

Everything seems to work except my Aeotec Z-stick Gen5. The led cycles as normal but Home Assistant can’t see it.

Did you find any solution? Anyone else?

*The differences between laptop and Pi was as follows : *
*Config check times : *
Pi running SD : 15-20 minutes
Pi running SSD : 10 minutes. (But problems rebooting)
*Laptop running HDD : 3,5 minutes. *

*Memory usage : *
Pi running SD/SSD : 27%
Laptop running Ubuntu 18.04LTS Desktop : 43%

I should probably have gone for Ubuntu Server.

Ok, I found my problem. Seems I forgot to install third party software when installing Ubuntu. I afterinstalled it and everything worked.

EDIT: Nope, after rebooting it disappears. After reinstall of Ubuntu it comes back. Next reboot it disappears again. It’s a shame, everything else is running great, but without the Z-stick it’s useless.