You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
xScheduledTask: Trigger has no option for Synchronize across time zones #109
Details of the scenario you tried and the problem that is occurring:
I have some Scheduled Task set up with xScheduledTask in the Daylight Saving Time on a Windows Server 2016. After End of the DST my Jobs run one hour early. But one hour early the other system was not ready. After removing the "Synchronize across time zones" in the schedule, the start time is the current time (Local Non DST).
I found no option to change the "Synchronize across time zones" this with xScheduledTask.
Hi @StefanSchoof - are you able to tell me which version of xComputerManagement you're using? There was a fix in v3.0.0.0 that hopefully addressed this.
Are you able to take a look at the MOF file that was used to apply to the node to see if it used 3.0.0.0? If it is using 3.0.0.0 and the problem still exists then there may still be an issue with daylight savings time.
I search my log and found that the Install-Module run on the 06. October 2017 and the first apply failed because I used the old syntax. I had a RepeatInterval = 1 which I removed. So I think I used 3.0.0.0 the whole time on this Server.
This must still be an issue then. But you are right, it doesn't look like the Synchronize across time zones is exposed in the resource. I couldn't actually find this in the New-ScheduledTaskTrigger cmdlet either - so I'll need to do some more digging to see where/how this gets exposed to PowerShell.
Deactivate the Hyper-V Time Synchronization Service
Change Time Settings: Settings -> Time & language -> Set time automatically: Off, Time zone UTC + 01:00 Amsterdam, ..., Change Date to 27 October (Had DST Change on 29. October)
Activity
PlagueHO commentedon Oct 30, 2017
Hi @StefanSchoof - are you able to tell me which version of xComputerManagement you're using? There was a fix in v3.0.0.0 that hopefully addressed this.
StefanSchoof commentedon Oct 30, 2017
Currently I have 3.0.0.0. I do not remember updating the module since I set up my task, but It is possible I did.
PlagueHO commentedon Oct 30, 2017
Are you able to take a look at the MOF file that was used to apply to the node to see if it used 3.0.0.0? If it is using 3.0.0.0 and the problem still exists then there may still be an issue with daylight savings time.
StefanSchoof commentedon Oct 30, 2017
I search my log and found that the Install-Module run on the 06. October 2017 and the first apply failed because I used the old syntax. I had a
RepeatInterval = 1which I removed. So I think I used 3.0.0.0 the whole time on this Server.PlagueHO commentedon Oct 30, 2017
This must still be an issue then. But you are right, it doesn't look like the
Synchronize across time zonesis exposed in the resource. I couldn't actually find this in theNew-ScheduledTaskTriggercmdlet either - so I'll need to do some more digging to see where/how this gets exposed to PowerShell.StefanSchoof commentedon Oct 30, 2017
Here a the steps for a repo:
Install-Module xComputerManagement. .\dsc.ps1ScheduledTaskStart-DscConfiguration -Path .\ScheduledTask\ -Wait -VerboseTake a look at the Task Scheduler

Next run time is at 5 AM
Change Time Back to 30. October
Take a lock again at the Task Scheduler

Next run time is at 4 AM
hassan041 commentedon Jan 17, 2020
Use Z at the end of time . it enables the option.
2018-06-14T19:00:00Z
Z at the end of the time does 2 things.
PlagueHO commentedon Jan 17, 2020
Thanks @hassan041 - it is possible we'll be able to improve this code in the future.