[Solved] Binding problems after 2.4 upgrade

Running openhabian on a raspberry pi.

After upgrading to 2.4, I’m seeing some strange hangs. The web interface only works sometimes, and the log shows errors followed by huge stack traces, often followed by new errors from insufficient memory. After attempting to install the new Zwave binding from PaperUI resulted in a hang, i rebooted and tried to install it via the karaf console. It hung there as well, and I needed to reboot again. After that, it shows the Zwave bundle as installed, and the PaperUI inbox shows discovered Zwave things, but they won’t add, with the log saying there is no binding for them. I suspect that something went wrong during the bundle install. When I try to uninstall from the console, it says that it’s uninstalled, but after waiting a little while and listing the bundles again, the Zwave bundle magically reappears.

When rebooting, it takes a long time for openhab to become operative, and sometimes it needs several reboots. After looking through the logs, it seems like the Network bundle is causing the first errors. On listing the bundles in the console, its status is always “waiting”. If I try to uninstall it, it hangs. If I try to stop it, it appears to hang, but after a while the error message “Exception in thread “ZWaveReceiveInputThread” java.lang.OutOfMemoryError: Java heap space.” Note that this happens when I try to stop the Network bundle. The console itself regularly become unresponsive.

Could someone please give me some pointers for how to completely remove and reinstall the Network and Zwave modules, so that these hangs hopefully stop?

1 Like

Maybe this link will help.

You can also increase the java memory by adding this to /etc/default/openhab2

EXTRA_JAVA_OPTS="-Xms400m -Xmx650m"

That thread seems to deal with finding which addon has a memory leak. My problem is that I can’t uninstall the Zwave binding and can neither uninstall nor even stop the Network binding.

A bit more detail, in case it helps:

The Network binding related log entry looks like this:

[ERROR] [org.openhab.binding.network         ] - bundle org.openhab.binding.network:2.4.0 (217)[org.openhab.binding.network.internal.discovery.NetworkDiscoveryService(257)] :  Error during instantiation of the implementation object

And it’s followed by a huge stack trace.

In the karaf console, bundle:list gives me the following for the Network binding:

217 │ Waiting  │  80 │ 2.4.0                  │ Network Binding

It always has the status “Waiting”. I can neither uninstall nor stop it. I would like to uninstall it because I don’t need it anymore, and it seems to be causing problems as can be seen from the above log entry.

As I said, I’m also having problems removing the Zwave binding. Doing bundle:list gives the following:

228 │ Active   │  80 │ 2.4.0                  │ ZWave Binding

It looks fine, but I can’t add Zwave things in PaperUI. I would like to remove it and reinstall it to see if that helps. But if i uninstall it through the console, it only disappears for a short while, before reappearing with a new ID.

If both PaperUI and Karaf console wont uninstall the binding then check that it’s not listed in /etc/openhab2/services/addons.cfg file. Then use the following commands to clean the cache.

sudo systemctl stop openhab2

sudo openhab-cli clean-cache

sudo reboot

If that fails to work please post the output of cat /var/lib/openhab2/config/org/openhab/addons.config or if you see the binding in this file you can stop OH and edit the file to remove the binding.

1 Like

I had already cleaned the cache, and that didn’t work. But I stopped the openhab2 service, removed both the network and the zwave bindings from addons.config,and then cleaned the cache again just to be sure before a reboot. Both of them now stayed removed and openhab is running clean and responsive again. :slight_smile: Thanks for helping! :slight_smile:

@kvolden Glad it’s working smooth again.:+1:

Please mark the topic solved by clicking the square box on post that provided the solution and edit the title to start with [Solved]. This help’s others with a similar issue find a quick solution.