Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with -RecurseCycle parameter. Scheduled task ends with code 0x1 #42

Open
farigiss opened this issue Oct 22, 2024 · 0 comments
Open

Comments

@farigiss
Copy link

I run the command Install-WindowsUpdate -AcceptAll -AutoReboot -RecurseCycle 5 -Verbose

Updates are installed, a reboot is forced, a task gets added to the task scheduler. The action of the task that gets created is
powershell.exe -Command "Get-WindowsUpdate -AcceptAll -Download -Install -AutoReboot -RecurseCycle 4 -Verbose *>&1 | Out-File $Env:TEMP\PSWindowsUpdate.log -Append"

Here's the issue:

The task ends with a 0x1 code.

The Out-File cmdlet does not produce any log file as far as I can tell. The task is executed as SYSTEM. $Env:Temp resolves to C:\Windows\Temp for that user. I cannot I cannot find a log file there.

I noticed the RecurseCycle parameter got added not too long ago. Is it unfinished?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant