Hi All,
I am attempting to run PowerShell scripts via a package, set up as shown in the attached image. The poc1.cmd is executed, which only contains the following line: powershell.exe .\poc1.ps1. The poc1.ps1 contains the powershell script.
What's happening is, if there's a short powershell script, it executes just fine, but if there's a longer script (maybe 2-3 minutes), it never finishes executing. Powershell.exe stays running and nothing happens. If I set this script to recur every hour, then a new Powershell.exe process starts up and stays running each hour.
The script, when run directly from the server, works fine every time, including when executed from poc1.cmd. Anyone have any ideas as to what I might be doing wrong, or have a suggestion to do it better?
Thanks,
DS