Forum Discussion
Taff4Ever
Mar 22, 2023Copper Contributor
PowerShell Novice: Script Timeout #WSUS
Hi I'm an idiot. Have to say this at the beginning so you are ready to help a moron understand what is happening!!! And in plain English, or crayon...... I'm trying to schedule a PowerShell...
Taff4Ever
Mar 23, 2023Copper Contributor
Thanks for the info and of course Google has given me some ideas on this, but my issues is what I should be adding to the script and where it should be.
I can’t seem to find a way to ensure there is no timeout for this as much of what I’ve read shows a specific time frame and wondered if it was possible.
I’m a complete novice with this so appreciate any feedback
I can’t seem to find a way to ensure there is no timeout for this as much of what I’ve read shows a specific time frame and wondered if it was possible.
I’m a complete novice with this so appreciate any feedback
LainRobertson
Mar 23, 2023Silver Contributor
You can't change the script, unfortunately.
The error itself is an SQL error, and you have no capacity for controlling the query timeout.
But by applying the indexes from the above article, you improve SQL performance on the WSUS database quite considerably (for certain functions), which greatly shortens the time it takes to finish, which in turn resolves this error condition.
In other words, you can't tackle this from the client side. You need to address it from the database server side.
Cheers,
Lain