Rule machine question about scheduling timed execution

Are you just looking to see if a device attribute has stayed the same way for >12 hours? If so, a much easier way would be: trigger on that attribute changing (use custom attribute if you need to), use the "And stays..." option if you're using at least Rule 5.1, then do whatever actions you want--say a notification, perhaps with a "Wait for event: certain time" before it if you care to be notified at 1 PM or some time instead of ASAP.

But, of course, that's just me guessing what you might want. :smiley:

there definately is a problem with the scheduler it still did not run again at 1 am.. i know the cron string looks ok but why is it not running every 12 hours.. here is the log from the run at 1 pm and the logs at 1 am showing no run..

weird maybe database corrupotion or something weird about 12 horus or maybe scheduling 12 hours with the first run more than 12 away..

not sure but deleted the trigger recreated with 4 hours and it is running every 4 hours..
trying 8 now.. will keep testing and see.

ok i think i found the issue.
my understanding of chron scheduling..

once you schedule something say every 8 hours starting at say 1 pm.. i would have thought it would run every 8 hours.

but no..
initially yes, but it appears when the day ticks over to a new day it will not run the first time till 1 pm EVEN if 8 hours from last run would have been say 10 am.

so the "starts at time" seems to reset every day.. so better to use a time like 12:00 am etc.

Every 12 hours starting a 1 AM would work fine. You are right, that cron breaks things down.

2 Likes

Although things appear broken, as an interim, can you have two triggers @ 01:00 and 13:00

1 Like