Jump to content

Scheduled Tasks running at wrong time after Time Change


Recommended Posts

DarWun
Posted (edited)

This is a minor annoyance at this point. But it is an annoyance all the same that I think is an issue with how Emby saves time settings for scheduled tasks. I've posted about this before.

I only get twice a year to troubleshoot this issue. And it is that time of year once again.

When the time change occurs, Emby changes the time for all scheduled tasks set to occur at a precise time in alignment with the time change. Troubleshooting tips provided by @Lukeand others last year (and six years prior in other posts) do not resolve the issue. In the past a few days after the time change Emby seems to self-correct.

Time rolled back today, and as per the norm all scheduled tasks in Emby with exact times to run have rolled back an hour as well. 

  • Server has been rebooted multiple times. All scheduled task times are still set to occur an hour earlier.
  • Time on the NAS is correct. It has been synced with the time server multiple times, followed by a full NAS shutdown and restart each time. All scheduled task times in Emby are still set to occur an hour earlier.
  • Times in Emby log files are correct. So Emby knows the time has changed.

Why are the times for scheduled tasks affected when the time on the server changes? The task has been set to occur at 8pm. Why does 8pm become 7pm when the time on the server rolls back an hour? If I change the time on the server manually, the time that the scheduled tasks runs does not change. So why is it changing when the time is automatically updated?

I'm posting this in the Synology thread this time, as from what was stated in prior threads where this was discussed is it may be a Linux specific issue.

 

Edited by DarWun
Posted

HI, yes this is a linux specific issue. On windows we're able to get notified when the system clock changes and automatically recover from that. We'll have to see if that's possible on linux.

  • Thanks 1
DarWun
Posted (edited)

I don't understand why the system clock change actually matters from Emby's perspective. After the time change, the server is reporting the adjusted time. Emby is reporting all activities based on the adjusted time. And log entries are all as per the adjusted time. So why are scheduled task item run times being adjusted? A task has been set to run at 8pm...8pm is 8pm regardless of the system clock (which is correct as per the adjusted time). If I change time zone settings on the server, the scheduled times for tasks do not seem to change in Emby. So why does Emby adjust those times when the server automatically updates twice a year?

Not trying to be a dick...I just don't get why this is still an issue after all this time. If the time set for scheduled tasks is actually being saved as EDT (UTC-4) or EST (UTC-5) instead of just the absolute time, then maybe that needs to be revisited.

Edited to add: Last post on this for another six months. This is really a minor "quirk" which I can live with. Like I said, it does seem to auto-correct after a few days.

Edited by DarWun
  • Agree 1
Posted

Because scheduled operations are based on the offset from when they are scheduled. When the system clock charges, the offset has to be recalculated.

TMCsw
Posted

Ya, why do scheduled recordings work, but not the tasks?

Posted
1 minute ago, TMCsw said:

Ya, why do scheduled recordings work, but not the tasks?

The same thing applies to them, but the timers are stopped and restarted during guide data refreshes and other internal operations.  So that must have happened in between the daylight savings change and the time in which the recording was supposed to happen.

  • Like 1
TMCsw
Posted
4 minutes ago, Luke said:

but the timers are stopped and restarted during guide data refreshes and other internal operations

So why can't that trigger a time reset?

Posted
2 hours ago, TMCsw said:

So why can't that trigger a time reset?

why can't what trigger a time reset?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...