Along the lines of Get-Service -Servicename ‘xxx’ | Set-service -Status Running It then restarts the application pools on IIS, and sends an email. The script workings when I run it manually but not when I trigger for the service’s recovery action.
submitted by /u/edgrant1992
[link] [comments]
The post Having problem using powershell script to launch on service recovery action. appeared first on How to Code .NET.