Windows Scheduled Task not working after a reboot

10,035

This can occur if the task trigger was set to run One Time when created. It is possible to set a task to "Run as soon as possible after a scheduled start is missed". This will cause the task to re-run after a reboot if the trigger was missed. However, this does not occur if the task is set to run One Time. This behaviour is by design.

You can work around this issue by setting a time and date under the Expire option of the task. This option can be reached by opening the Properties of the task, selecting the Triggers tab, and then clicking the Edit button for the trigger in question. If a date and time are set for the Expire option, the task will attempt to refire on reboot if its previous trigger time was missed.

I suggest you to set the trigger to "At startup". After you rebooted the machine, the task should then be in the "Queued" status. This means it will run at the configured interval.

Share:
10,035
Xangrim
Author by

Xangrim

Developer of Access/MS SQL Server databases, Excel reports and PowerShell scripts.

Updated on June 04, 2022

Comments

  • Xangrim
    Xangrim almost 2 years

    I have created scheduled tasks to run each day at various times in the morning, on 6 different machines, all running Windows 7 x64.

    These tasks have largely worked over the last few years, but we have a persisting issue with tasks not triggering at times, and never after a restart.

    Without touching the Task Scheduler application at all, restarting the machine will mean that the next time the task is meant to be triggered, it doesn't work.

    Running any task manually after the restart appears to avoid the issue.

    This issue exists for scheduled batch files and PowerShell scripts.

    Is there a specific setting that is needed to keep the task working after a system restart, or is this a known outstanding issue?

    The most recent time this happened, we have captured the history:

    Error       | 27/02/2017 03:15:00 | 101 | Task Start Failed
    Information | 27/02/2017 03:15:00 | 107 | Task triggered on Scheduler
    
    Result code for failure: 2147943645
    

    Update 2017-03-01: One machine doesn't work and produces the above error, and another machine shows nothing at all. Clutching at straws about this issue here.

    If I tick the box 'Run whether user is logged on or off' The task is invisible. We can't do this. Any other suggestions are welcome!

    Update 2017-03-02: Ticking 'Run whether user is logged on or off' is causing no end of issues. None of our Access macros run anymore, and other 3rd party applications called from the batch don't work with numerous permission errors. This is not the solution!

  • Xangrim
    Xangrim about 7 years
    Thanks for finding, we will put this in place ready for tomorrow's tasks. Will mark when we're more sure :)
  • Xangrim
    Xangrim about 7 years
    We changed the setting yesterday, and now the task ran half-way but invisible. If there was a genuine error in that task, we were unable to see it.