Windows Server 2022 Scheduled Task issue

New Contributor

I discovered yesterday that multiple scheduled tasks suddenly stopped working on a 2022 server. The tasks and the paths to the scripts they run have not changed in months. Last confirmed success was Feb 28th. The tasks run as an Active Directory account with permissions to run scripts on a network share, that hasn't changed either.

 

I get the error code FFFD0000 as "Last Run Result" and in the History tab it also gives the exit code 4294770688. By extensive research online these codes mainly point to:

* The script having an incorrect -File path.

* The -File path to the script is relative.

* The -File path does not include double quotes around it.

* Then path to powershell.exe needs to contain the full path, not just the file name.

None of these issues were affecting my tasks.

 

What is weird is that it works if I select "Run only when user is logged in". But not when I select "Run wether user is logged in or not" and enter the password so that it is stored within the task.

I have confirmed this with another high privilege AD account as well, on two separate 2022 servers, and it gives the same FFFD0000 and 4294770688 errors.

Exporting a task to 2016 or 2019 servers, and running them = success

 

Also:

It works if I run a cmd prompt as the user and then run the same command line:

C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy Bypass -File "\\my.domain\PathToScript.ps1"

It works if I run PowerShell ISE as the user, browse to the scripts and run them.

It also works if I move the script to the server locally, for example "C:\temp\script.ps1"

Tasks running as SYSTEM on the 2022 servers also work.

 

The 2022 servers are all patched with the March cumulative updates.

 

Can anyone else confirm this?

0 Replies