Start issue after upgrade

I have not had the need to clean the cache with openHAB 3 yet, so there may have been a change in that area. I cleaned the cache a lot under 2.5.x it was a pain probably 5% of the time. Most of the time it was smooth, but occasionally something went really wrong and it took multiple cleans and restarts to fix.

3 restarts of openHAB usually fixes most issues, so ignore any errors till that is done.
I also found that a clean and then restarting linux would result in more pain, a clean and then only restart openHAB would be less likely to be painful.

As mentioned I have not seen it in openHAB 3 yet.

Five times … is a bit of an exaggeration. Or at least I left out the “clear cache” after restart number three.

Anyway: although i did a lot of analysing, you may be right. I appreciate your offer.

Before starting more analyis with the help of others, i’d really like to know is, if beloved “feature” will be gone with v3.

Maybe better to ask in 3.0 discussion though.

Problems with boot-up sequence interactions have been a plague since OH1 days. Each release changes the exact symptoms a bit - this file gets fatter, that initialization job is improved - but it’s whack-a-mole.

I’ll predict OH3 comes with its own completely different manifestation. :crazy_face:

1 Like

I followed a lot of dicussions about the feature i described above (oh possibly running rules before having read items etc.). I really wonder about why this feature is quite well accepted by most(?) contributors.

And now I felt I should point it out again.

Sorry for getting of topic here.

Looks like you’re using the same cystall ball as me. :wink:

As you might guess, it is because there is no easy fix. The underlying non-openHAB Karaf framework offers poor control here.
Start reading here -


and here -

A lot of all this i red a while ago. Didn’t understand all (no to say most, can’t remember). But that is why …

Sorry to say that.

1 Like

This „feature“ never happend to me since I stopped using text files. Maybe try using UI based configuration.

Every time you delete the cache, you need to make two restarts (without deleting the cache).
Otherweise you´ll end up exact the same :slight_smile:

3 restarts before a system act “normally” is bad in itself. I know it has been chosen by design. But those who choose this design probably does not run a huge system and/or a low resource HW, (like Rpi)… Otherweise they´ll know, why restarting several times is wrong! It have seen people mention it takes 10-15 minutes each time. That potentionally means the system will be offline for at least 45 minutes.

I sure would like to know if openHAB3 suffer from the same kinda design?

It went from a plauge to very bad plauge in openHAB 2.5, and as far as I recall even worse in openHAB 2.5.x. Thats my experience.

I had also a little problem after the update, but I remembered this was similar to earlier 2.x versions where some of my items were not loaded.
I found a tip in this forum to “touch” the files in the “items” directory, this solved my problems without a further restart or reboot.

2 Likes

Good to read. I’m only using PaperUI for discovery, text files for the rest. Where do you define rules f.e.? Or are you talking of items only?

This makes oh reread the item files, what is what is needed. Fine you are mentioning it - i knew but … getting older. :wink:

That would make sense as I stopped using textual config when I moved to V3.

I just timed it on my Odroid N2+ rig, it is 1 min 47 seconds to stop and start a single time here.

Give it a shot with an Rpi3 and SD card including at huge system with alot of things and zillions items :slight_smile:

Just to let you know: i asked Markus to take this whole part out of the 2.5.10 discussion.

1 Like

If you are on the snapshots there will be a clearing of the cache every time you move to a new build.

I’ve never personally seen this issue when the Things and Items are stored in JSONDB instead of .things and .items files, even on OH 2. I’ve never seen it occur on OH 3 but I’m putting everything (rules too) into JSONDB at this point so probably wouldn’t have seen the problem anyway.

I guess something like 200 man hours have been spent trying to find a solution for it so far. It’s not that it’s acceptable, no one has found an acceptable solution despite trying. As rossko has said, this is a problem that has always existed and many many developers and maintainers have taken a shot at solving the problem.

It’s a work around for a problem/bug that has no other solution right not. It’s not by design. No one chose this approach. No one designed and implemented this. Through trial an error, largely by users here on this forum, the 2-3 restarts was found to work around the problem.

On OH 2.5 it’s probably not worth it. ON OH 3…

And for import/export/sharing on the forum:

If you do want to do this in OH 2.5, you need to install the Experimental Rules Engine and then a Rules item will appear in the PaperUI Menu. But PaperUI’s rules editor is mostly broken so I can’t recommend it. Though if you want to switch over to JavaScript or Jython or Groovy as your rules language I can’t recommend it enough. But you’ll still want to write your rules in text files. For Jython you can get started at [beta testers wanted!] Jython addon w/ helper libraries (requires OH 2.5.x).

I use JavaScript in files vor Rules. Items/Things in database.

I remember having red a lot about several tries to “find a solution”. So probably i should not have written the above statement. I really appreciate the work of all contributors.

Although i read a lot here, i never realized that using jsondb for items works around the restart twice feature. And i forget, that touch’ing’ the item files can help. Maybe some day the raspi will come over to to get its ports fondled. ^^

As you may read, i’m in a better mood than i have been when i wrote the first post above. I’ve been really p* off at that time and you’re lucky not having got to read my first version.

I understand that i have to live with this feature. Even though there are chances to minimize the occurance of the rule telling the item “I’m already here!”.

I think I’m not going to change my config in oh2 anymore. But i’m looking forward to oh3. Even if there will be tons of new features (we hopefully don’t need any workarounds for).

1 Like