Strange add-ons behaviour on Rpi 3B+

Hello all, i’m new to OH2 so sorry for any errors trying to explain my actual problem

I’m on RPi 3b+ with Openhabian 2 v2.5.0.SNAPSHOT

Just configured some items (sonoffs basic anc pow) and got it to use basic functions (reading power, switch on-off). All is ok here.

During my first testing i’ve also installed (via PaperUI) some extra bindings, like GPSTracker and Network bindings to play with some basic presence functions and Habmin.

All these add-ons get installed and appear to be ok, BUT after rebooting Rpi, all these modules are not available anymore. To get them working, i’ve to reinstall them again until the next Rpi… and so on.

I’ve already made an off-line fscheck on my sdcard and verified that root was mounted rw without errors.

Any hints on this?

TIA
h

Also i’ve installed Habmin

  • Issue of the topic: please be detailed explaining your issue
  • Please post configurations (if applicable):
    • Items configuration related to the issue
    • Sitemap configuration related to the issue
    • Rules code related to the issue
    • Services configuration related to the issue
  • If logs where generated please post these here using code fences:

You may want to consider installing the milestone build rather than the snapshot. Snapshots can be a little unstable these days while major reorganizations take place.

Did you by chance edit the addons.cfg file (you can find it in the folder “services”)? The original file has all elements commented out, i.e. all lines start with the hash sign “#”. This file can be used for manual configurations, but any entries in this file will overwrite any changes you made in PaperUI, so use either this file OR PaperUI, but not both.
If you did not, you may want to try to Clear the Cache, this sometimes works wonders.

Thank you lipp_,

about downgrading to milestone build, do you think it is possibile without messing up my setup?
Do you have some suggestions to get this downgrade?

About the addons.cfg file, i never touched it. I’ve also checked it few minutes ago and, even if i’ve the add-ons installed visible in PaperUI, the addons.cfg file is ‘inconsitent’ about some lines (ie in the binding one, i can see only mqtt despite network and gps are installed)

After clearig the cache i’ve got these errors in the logs and cannot get my original installation up and running again.

Any help appreciated :wink:

h

2019-03-09 09:55:04.643 [ERROR] [core.karaf.internal.FeatureInstaller] - Failed installing 'openhab-misc-mqttbroker, openhab-persistence-mqtt, openhab-action-telegram, openhab-binding-mqtt, openhab-ui-basic, openhab-misc-openhabcloud, openhab-ui-habmin, openhab-ui-habpanel, openhab-misc-ruleengine, openhab-ui-paper, openhab-transformation-jsonpath': Unable to resolve root: missing requirement [root] osgi.identity; osgi.identity=openhab-ui-habmin; type=karaf.feature; version="[2.5.0.SNAPSHOT,2.5.0.SNAPSHOT]"; filter:="(&(osgi.identity=openhab-ui-habmin)(type=karaf.feature)(version>=2.5.0.SNAPSHOT)(version<=2.5.0.SNAPSHOT))" [caused by: Unable to resolve openhab-ui-habmin/2.5.0.SNAPSHOT: missing requirement [openhab-ui-habmin/2.5.0.SNAPSHOT] osgi.identity; osgi.identity=pom; type=osgi.bundle; version="[2.5.0.201903031308,2.5.0.201903031308]"; resolution:=mandatory [caused by: Unable to resolve pom/2.5.0.201903031308: missing requirement [pom/2.5.0.201903031308] osgi.wiring.package; filter:="(&(osgi.wiring.package=org.apache.commons.codec.binary)(version>=1.10.0)(!(version>=2.0.0)))"]]

2019-03-09 09:55:17.275 [ERROR] [core.karaf.internal.FeatureInstaller] - Failed installing 'openhab-misc-mqttbroker, openhab-persistence-mqtt, openhab-action-telegram, openhab-binding-mqtt, openhab-ui-basic, openhab-misc-openhabcloud, openhab-ui-habmin, openhab-ui-habpanel, openhab-misc-ruleengine, openhab-ui-paper, openhab-transformation-jsonpath': Unable to resolve root: missing requirement [root] osgi.identity; osgi.identity=openhab-ui-habmin; type=karaf.feature; version="[2.5.0.SNAPSHOT,2.5.0.SNAPSHOT]"; filter:="(&(osgi.identity=openhab-ui-habmin)(type=karaf.feature)(version>=2.5.0.SNAPSHOT)(version<=2.5.0.SNAPSHOT))" [caused by: Unable to resolve openhab-ui-habmin/2.5.0.SNAPSHOT: missing requirement [openhab-ui-habmin/2.5.0.SNAPSHOT] osgi.identity; osgi.identity=pom; type=osgi.bundle; version="[2.5.0.201903031308,2.5.0.201903031308]"; resolution:=mandatory [caused by: Unable to resolve pom/2.5.0.201903031308: missing requirement [pom/2.5.0.201903031308] osgi.wiring.package; filter:="(&(osgi.wiring.package=org.apache.commons.codec.binary)(version>=1.10.0)(!(version>=2.0.0)))"]]

You can backup your files using openhab-cli backup in your RpI, perform a downgrade and restore with openhab-cli restore your configuration, this will make a backup copy of all files and databases that are important to your configuration and restore them. If you want to be on the safe side, you can also pull a copy of the resulting zip file on another drive before downgrading. It would recommend a downgrade to either 2.5M1 or 2.4. just to rule out some factors.

I am not sure I understand, you may need to post the content of your files at some point here. But any text line in this file will need to start with # otherwise, whatever is in that line will overrule any change you made in PaperUI. In a standard installation, all content in this file is commented out and OH2 will not write to this file (it will only read this file). If you have uncommented text lines, go ahead, stop PH2, add the “#” the beginning of each line, safe, clear your cache and restart OH2.

Thank you very much for your help.
I’ll give it a try as soon as i get some time available here.

I’ll keep you informed… :wink:

h

Hello lipp_
just to update…

i’ve reverted my installation back to 2.4 stable. Now is a clean and fresh install (at least i think, since OH show me the very first dashboard where it is possibile to choose from one of installation methods… Demo, Expert, Standard. etc…)

Now, before make any modification, i would like to hear some advices from you gurus about the text configuration files and the other modifications made by web gui.

If i’m not wrong, text files take always precedence over any modification med in gui - right?
At least from what i’ve seen in my last ‘experiment’ with 2.5-SNAPSHOT: even if i make modifications in gui, OH2 took always what’s in its config files.

I noticed that if i add things and items from the gui, that objects are then stored in a json db apart from the config files under /etc/openhabian2/ dir - again if i’m not wrong :wink:

This is confusing me a little and a wonder if there is a way to have all modifications made in the gui (ie PaperUI) stored in a bunch of text files also.

TIA

h

Yes, but it isn’t immediate. For example, if you use addons.cfg and then install a binding through PaperUI, the binding will get installed and probably run for awhile. Eventually though the binding will get uninstalled.

It’s also important to avoid duplicating Items and Things in both places. If you do there can be some unexpected and undesirable behavior.

That is indeed where the Things and Items and Links are stored when they are created through the REST API (which is how PaperUI does it) or the Karaf Console.

The answer to the question as you mean it is no. The full answer is JSONDB IS a bunch of text files. But there is no way for PaperUI to write out to .items files (et al).