New zwave device fails, attempts to fix leads to all new thing names, breaking item links and rules

I was away for a week and returned to two new zwave devices in the mail.

I’m on openhabian snapshot.

I added the first and it was found but not recognized as in the database. (Strange since it has been there for over a year…)

So I removed it and used openhabian-config updated to the latest snapshot.
I shutdown OH and rebooted the pi.

At that point all my devices except the hub (Aeotec gen5 usb stick) showed as not initialized.

I then added the NZW36 and it was included just fine. But could not be switched on/off.

BUT! a new usb controller controller also showed up. (a duplicate of the first)

So, I added it. It showed as off-line because the serial port was in use.

So, I removed the original one.
Then the new one went on-line and all my devices showed up as newly added devices (all with different names from the originals, most notably all have format, for example: zwave:device:512:node13:switch_dimmer as opposed to the original: zwave:device:16500637f6a:node13:switch_dimmer. Note the 512 instead of 16500637f6a.)

So, now I have a whole bunch of devices whose names don’t match the previously associated items.

And a bunch of old things that I had to disassociate from the items, before they’d link to the new.
And a bunch of rules that are probably broken.

I only have 16 devices now, so fixing it was annoying, but, doable.

What I want to avoid is when I have 100 devices and lots of rules having to re-do this.


  • what did I do wrong?
  • what should I do to avoid this in the future?
  • what don’t I understand about thing names?


You missed the fact that there was a major update to the ZWave binding that requires you to delete and rediscover your things.
See this thread for details.

This thread may be helpful too…

Ok, indeed I missed that and I even saw the emails from merges. :blush:

But, still am confused as to the difference in the name ( 16500637f6a vs. 512 ).

I have not at looked how the thing name change effects my rules. The “new” things had to be re-associated with the old items, though.

And the old things are just labeled “Removing” and don’t go away.

It’s a randomly(?) generated ID for the new controller thing, you can change it to whatever you want during creation, here:


For example, i’ve renamed mine to be “zStick” so all my zwave things show like this: zwave:device:zStick:node2:switch_binary. This can be helpful in the future if you ever have to delete the controller thing

1 Like

Do you mean the ThingID for the controller? This shouldn’t change, as the instructions state to not delete the Thing for the controller. If you did, and added a new Thing for the controller, just delete it again, add it again with the ThingID that you had before. Check your items files (if you have them) for what it was. Then your items will not need to be changed.

But you can also start all over again too. Do a search and replace in your item files with the old/new ThingID and everything should come back up.

Well, since I barged through things before knowing about the instructions, I did delete the old controller thing and add the newly found one.

Since the things and the items were added in habmin/paperui I don’t have thing/item files I can edit right?

I now have new things with the new controller thing id. And, additionally, I have all the old things with the old controller id. And these won’t go away. If I click the trashcan, they get marked “REMOVING”, but never disappear. I tried the clear cache trick and they all came back marked “UNINITIALIZED”.

Another way to find the old ThingID for the controller is to go into Karaf and type:

smarthome:things list

Then look for one of the old Things. They will look something like this…

zwave:device:55555:node112 (Type=Thing, Status=ONLINE, Label=Z-Wave Node 112: WAPIRZ-1 PIR Motion Detector, Bridge=zwave:serial_zstick:55555)

Then create a new controller that uses the old ThingID. In my example, it would be 55555. Then discover your Things again and they will come online with links to your items…

Actually, you should also be able to go into PaperUI> Configuration> Things, select one of the old Things, and look under the channels. The old controller ThingID will be displayed there too.

I see no way in habmin or paperui to create a controller with a specific ThingID.

In either when I do a scan it finds the controller, no option to set a ThingID. After that the ID is set to 512.

In PaperUI, go to the Inbox. Click the big blue button, select Zwave, click Add Manually, select serial controller. One of the first fields is ThingID…

Ok, so I now have a controller with the old ThingID.

But, the old things that match that ID still show as “UNITIALIZED”.

If I remove one then scan again it shows up as online, but the device can’t be controlled and I get java Null pointer errors in the log:

2018-09-13 09:53:29.480 [ERROR] [] - Dispatching/filtering event for subscriber '' failed: null

java.lang.NullPointerException: null

	at org.eclipse.smarthome.core.thing.internal.AutoUpdateManager.receiveCommand( [100:org.eclipse.smarthome.core.thing:]

	at org.eclipse.smarthome.core.thing.internal.CommunicationManager.receiveCommand( [100:org.eclipse.smarthome.core.thing:]

	at org.eclipse.smarthome.core.thing.internal.CommunicationManager.receive( [100:org.eclipse.smarthome.core.thing:]

	at sun.reflect.GeneratedMethodAccessor37.invoke(Unknown Source) ~[?:?]

	at sun.reflect.DelegatingMethodAccessorImpl.invoke( ~[?:?]

	at java.lang.reflect.Method.invoke( ~[?:?]

	at org.eclipse.smarthome.core.internal.common.AbstractInvocationHandler.invokeDirect( [94:org.eclipse.smarthome.core:]

	at [94:org.eclipse.smarthome.core:]

	at [?:?]

	at java.util.concurrent.ThreadPoolExecutor.runWorker( [?:?]

	at java.util.concurrent.ThreadPoolExecutor$ [?:?]

	at [?:?]

Oh, and the controller shows up every time I do a scan.

The controller showing up is something new from ESH with USB discovery. You can add it and ignore it, or mark it to be ignored in the Inbox.

The error I’m guessing is a new issue related to the refactoring of autoupdate. Which version of OH are you running? I haven’t looked yet, but there may be an issue for this.

If you have still not deleted and rediscovered all the old Things, you will need to do this to pull in the new Thing definitions.

This is the latest snapshot of openhabian as of yesterday.

I have removed all the old things. Then rediscovered (only a couple to test at this point).

They show as online. But, for example I added a switch to a NZW36. But, clicking the switch in PaperUI > Control does nothing…except generate the previously shown error in the log.

What version do you see when you start Karaf? It will give you a build number. The latest is build 1361. I’m still on 1348, but I should have some time later today to try out 1361 in a test environment. I’m only guessing, but this may be related to…

This is build 1360

I’m curious… did you have to relink all of your items after deleting/rediscovering the Things? When using .items files, the links are reestablished when the Things come back in, because the channels are the same. I wonder if you would get the same error if you created an item in a .items file.

I updated to 1361, no change, didn’t really expect any. just getting to the latest.

So, having used habmin/paperui I’ve never done an item file for any of my zwave devices. I have item files for things like astro things and what I use for variables in rules…

I started an item file for one of the switches I rediscovered but realized I don’t know how to specify the channel. This is what I have so far:

Switch Swt_Itm "Itm File Swt" {channel="zwave:device:16500637f6a:node11:switch_binary"}

This particular switch has channels: “Switch”, “Electric Meter (amps)”, “Electric Meter (kWh)”, etc.

That looks correct. In the channel info in Habmin and PaperUI, there is an option to copy it to your clipboard, then you can paste it into your items file.

With all the updating you’ve done, I would expect you’ve done it a few times… but do you still get the error after an OH restart?

ok, so I saved that in an .items file. Then for good measure shutdown OH, then reboot.

Now in PaperUI > Control I get this:


“Itm File Swt” from the file and “Amber Lamp” from created by habmin/paperui from before.

“Itm File Swt” controls the device, no error in log.
“Amber Lamp” does not control the device, logs the error.