Well, seems like I´m about to give up find the reason why Grafana 5.1.4 needs PhantomJS.
This is the error I get:
t=2019-01-09T23:56:37+0100 lvl=info msg=Rendering logger=png-renderer path="d-solo/UgPbUoggz/stort-bad?refresh=30s&orgId=1&panelId=4&from=1547052995409&to=1547074595409&width=1000&height=500&tz=UTC%2B01%3A00"
t=2019-01-09T23:56:37+0100 lvl=eror msg="Could not start command" logger=png-renderer LOG15_ERROR= LOG15_ERROR="Normalized odd number of arguments by adding nil"
t=2019-01-09T23:56:37+0100 lvl=eror msg="Rendering failed." logger=context userId=1 orgId=1 uname=admin error="fork/exec /usr/share/grafana/tools/phantomjs/phantomjs: no such file or directory"
t=2019-01-09T23:56:37+0100 lvl=eror msg="Request Completed" logger=context userId=1 orgId=1 uname=admin method=GET path=/render/d-solo/UgPbUoggz/stort-bad status=500 remote_addr=10.4.28.30 time_ms=15 size=1703 referer="http://10.4.28.237:3000/d/UgPbUoggz/stort-bad?refres$
I renamed the PhantomJS file back to its original name. Then I took a look at @matt1 suggestions for the changes in the link he provided.
I changed the /etc/default/openhab2 to
EXTRA_JAVA_OPTS="-XX:+HeapDumpOnOutOfMemoryError -Xmx512m"
And then rebooted.
After this, I can render 3 charts wihtout a problem, (almost)… It seems like something else fails when I do so.
2019-01-10 00:06:32.003 [WARN ] [su.litvak.chromecast.api.v2.Channel ] - Error while reading
su.litvak.chromecast.api.v2.ChromeCastException: Remote socket closed
at su.litvak.chromecast.api.v2.Channel.read(Channel.java:425) ~[235:org.openhab.binding.chromecast:2.4.0]
at su.litvak.chromecast.api.v2.Channel.access$200(Channel.java:51) ~[235:org.openhab.binding.chromecast:2.4.0]
at su.litvak.chromecast.api.v2.Channel$ReadThread.run(Channel.java:137) [235:org.openhab.binding.chromecast:2.4.0]
2019-01-10 00:06:32.060 [WARN ] [su.litvak.chromecast.api.v2.Channel ] - <-- null payload in message
==> /var/log/openhab2/events.log <==
2019-01-10 00:06:32.084 [hingStatusInfoChangedEvent] - 'chromecast:chromecast:255f3cf49521e13fa5f92fc38ae7ac51' changed from ONLINE to OFFLINE
2019-01-10 00:06:32.098 [hingStatusInfoChangedEvent] - 'chromecast:chromecast:255f3cf49521e13fa5f92fc38ae7ac51' changed from OFFLINE to OFFLINE (COMMUNICATION_ERROR): Interrupted while waiting for response
It does come back to online again a few seconds after.
2019-01-10 00:06:42.472 [hingStatusInfoChangedEvent] - 'chromecast:chromecast:255f3cf49521e13fa5f92fc38ae7ac51' changed from OFFLINE (COMMUNICATION_ERROR): Interrupted while waiting for response to ONLINE
This only happens sometimes…
Whats good, openhab doesn´t seem to crash, even though I´m using PhantomJS and rendering… I have thought about that maybe webview would be better… It´s alot faster. I have not tested how much memory it takes though. I´ll keep an close eye on the system the next few days… I dont really trust it atm.
However I still wish I could find the reason why Grafana needs PhantomJS using version 5.1.4. From what I´ve read, it´s required from version 5.2.0 only.