All timed rules stopped working.... no idea why

Hi all,

suddenly all me timed rules like this one

rule "Temperatursteigerung Büro Nati"
    Time cron "0 30 21 * * ?"
    sendCommand(EG_Buero_Heizung, 23)

stopped working today.
I have timed rules for rollershutters, decoration light and heating temperatures.
In the morning everything worked fine. But today in the evening they didn’t worked and they arent working till now.

I already checked if I can trigger the actions in openhab using my sidemap… thats working fine. I was able to move a roller shutter with openhab app. I changed the time for the rule to the current time +1 minute and waited till the time. Nothing happend. I also checked the logviewer and it wasn’t even a action visible. Time in logviewer matches the current time…

So I have no idea whats the problem… have you any ideas?

Depending on the version of OH, you can have only 2 (2.4 or older) or 10 (2.5 or newer) time based threads running at the same time. This includes Time triggered Rules, Timers, and Astro event triggered Rules. I’m sure there are more.

If you have reentrant locks, Thread::sleeps, long running calls like executeCommandLine, or errors that cause a rule not to exit, you can quickly run out of the available threads. Look for errors and analyze your Rules to see if you might have too many of these sitting around waiting.

1 Like

Hey Rich

My Openhab has verion 2.4.0-1

Im just started with creating my first rules and I have 90% rules like the rule in the first post. This is just for the start of my smart home because there are better indiciators other then just the time. So a lot of them will be changed in the future. but maybe thats the cause of the issue… a lot of rules waiting to reach a specific time.

I solved the issue by restarting the PI which is running my openhab… but from my point of view this should not be necessary… so I have to find the real solution

It’s not a problem of how many Rules are waiting to be triggered. The mere fact that you have a Rule with a Time trigger doesn’t consume a thread. Only actively running Rules consume a thread. So you can only have two running at the same time. This is why it’s important not to have Rules that take a long time to run or have a chance that they never return.

1 Like

I think there were only 2 cron (quartz) threads in 2.4.x. That number has been bumped to 10 in 2.5.x.

@c0rtez Is there a reason why you’re using 2.4 when 2.5 stable is out?

1 Like

Thanks @rlkoshak and @mhilbush

got it now. I have 2.4 running because I just havent updated yet… update is in progress while writting this
lets see if that helps

Thanks a lot

1 Like