Hello,
info: openhab running on a pi3+
Recently, i’ve updated my openhab from 2.3to 2.4. I aslo i added spotify (+market) binding, adjusting stuff in habpanel and sitemap for the new binding and did some more rule. After a couple days i’ve notice that habpanel wouldn’t load anymore. I checked the log and see the famous java heap problem:
2019-10-13 09:58:02.015 [INFO ] [ui.habmin.internal.servlet.HABminApp] - Started HABmin servlet at /habmin
2019-10-13 09:58:08.463 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '**IPADDRESS**' with clientid paho79431135232 and file store '/var/lib/openhab2/mqtt/**IPADDRESS**'
2019-10-13 09:58:25.412 [INFO ] [mmandclass.ZWaveDoorLockCommandClass] - NODE 6: Door-Lock config report - timeoutEnabled=false timeoutMinutes=254, timeoutSeconds=254
2019-10-13 17:56:39.655 [ERROR] [o.client.mqttv3.internal.ClientState] - paho79431135232: Timed out as no write activity, keepAlive=60,000 lastOutboundActivity=1,571,003,534,821 lastInboundActivity=1,571,003,670,914 time=1,571,003,703,024 lastPing=1,571,003,534,821
2019-10-13 18:13:44.897 [WARN ] [e.jetty.util.thread.QueuedThreadPool] - Unexpected thread death: org.eclipse.jetty.util.thread.QueuedThreadPool$2@2d4e16 in QueuedThreadPool[HttpClient@e2509f]@1bad41e{STARTED,8<=8<=200,i=5,q=0}[ReservedThreadExecutor@12d80b{s=0/4,p=0}]
2019-10-13 18:25:36.709 [WARN ] [e.jetty.util.thread.QueuedThreadPool] - Unexpected thread death: org.eclipse.jetty.util.thread.QueuedThreadPool$2@8bcebf in QueuedThreadPool[HttpClient@1c2769d]@1c01699{STARTED,8<=8<=200,i=5,q=0}[ReservedThreadExecutor@b450f6{s=0/4,p=0}]
2019-10-13 18:25:28.228 [WARN ] [me.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.eclipse.smarthome.core.internal.items.ItemUpdater@16525e8' takes more than 5000ms.
2019-10-13 18:25:21.105 [WARN ] [e.jetty.util.thread.QueuedThreadPool] - Unexpected thread death: org.eclipse.jetty.util.thread.QueuedThreadPool$2@1c5c303 in QueuedThreadPool[HttpClient@936858]@c4d222{STARTED,8<=8<=200,i=5,q=0}[ReservedThreadExecutor@1fa50a3{s=0/4,p=0}]
2019-10-13 18:26:49.040 [WARN ] [e.jetty.util.thread.QueuedThreadPool] - Unexpected thread death: org.eclipse.jetty.util.thread.QueuedThreadPool$2@1a57005 in QueuedThreadPool[HttpClient@152e1d0]@436c3d{STARTED,8<=8<=200,i=5,q=0}[ReservedThreadExecutor@1629801{s=0/4,p=0}]
2019-10-14 03:00:45.261 [WARN ] [me.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.eclipse.smarthome.io.monitor.internal.EventLogger@b22679' takes more than 5000ms.
2019-10-14 03:08:12.668 [ERROR] [WaveSerialHandler$ZWaveReceiveThread] - Exception during ZWave thread.
java.lang.IllegalStateException: Queue full
at java.util.AbstractQueue.add(AbstractQueue.java:98) ~[?:?]
at java.util.concurrent.ArrayBlockingQueue.add(ArrayBlockingQueue.java:312) ~[?:?]
at org.openhab.binding.zwave.internal.protocol.ZWaveTransactionManager.processReceiveMessage(ZWaveTransactionManager.java:404) ~[240:org.openhab.binding.zwave:2.4.0]
at org.openhab.binding.zwave.internal.protocol.ZWaveController.incomingPacket(ZWaveController.java:1062) ~[240:org.openhab.binding.zwave:2.4.0]
at org.openhab.binding.zwave.handler.ZWaveControllerHandler.incomingMessage(ZWaveControllerHandler.java:643) ~[240:org.openhab.binding.zwave:2.4.0]
at org.openhab.binding.zwave.handler.ZWaveSerialHandler$ZWaveReceiveThread.run(ZWaveSerialHandler.java:316) [240:org.openhab.binding.zwave:2.4.0]
2019-10-14 17:27:40.840 [WARN ] [org.eclipse.jetty.server.HttpChannel] - /habpanel/app/widgets/frame/frame.widget.js
java.lang.OutOfMemoryError: Java heap space
2019-10-14 17:27:40.840 [WARN ] [org.eclipse.jetty.server.HttpChannel] - /habpanel/app/widgets/chart/chart.widget.js
java.lang.OutOfMemoryError: Java heap space
2019-10-14 17:28:06.315 [WARN ] [e.jetty.util.thread.QueuedThreadPool] -
java.lang.OutOfMemoryError: Java heap space
//and so on...
It’s talking about Z-wave in this example, but in other it’s talking about MQTT and in another it’s the execution of a rule that normally is woking normally. I think it’s only a coincidence that this program call something and the java heap space is already full.
Since the first error, i’ve uninstall openhabcloud, market, spotify, network and astro bindings. I’ve commented all the code referring to those even in the sitemap. With no result at all.
I’ve doubled the max heap size and activate creation of .hprof in the file /etc/default/openhab2:
EXTRA_JAVA_OPTS="-Xms250m -Xmx700m"
EXTRA_JAVA_OPTS="-XX:+HeapDumpOnOutOfMemoryError"
The heap size hasn’t done anything, it’s still give me the error ususally a ocuple of hours after a reboot. Here’s the result of the .hprof analyser: ( I analyse 3 differrent .hprof with the same result)
But this i cant really make sense if someone could help me.
There is also this error file i found that give some guideline that i’ll to follow next but i don’t have much faith in that…
hs_err_pid30247.log (16.3 KB)
I’m at a point where i would just wipe out the pi and do it all over. It wouldn’t be that much work but i fear that problem would be back after a while…
So if someone could shed some light upon this i think it would help a lot of people
Thanks