Previously, I stumbled upon a peculiar issue where my PowerShell scripts in SCORCH are not executing the SMLets commands. SMLets are properly installed in both my Service Manager Management Server as well as my SCORCH server. The servers are all Virtual Servers, running Windows Server 2016.
When I tested the PowerShell script (with SMLets) on Windows PowerShell ISE, everything works perfectly. In SCORCH, the PowerShell script will always fail. An example of my failed PowerShell script/activity is shown below.
After much research without any success, I asked a colleague of mine if he has seen this type of issue before, and whether he has any solution for me. When he got back to me and asked me to try again, my PowerShell scripts finally manage to work.
I asked him, what kind of magic did he use, when everything else I tried didn’t even come close to fixing it. Apparently, the solution was a simple one, although it took my colleague a few days to find it. So here it is, the fix to the issue that bugged me for so long.
Copy the SMLets folder from “C:\Windows\System32\WindowsPowerShell\v1.0\Modules” to “C:\Windows\SysWOW64\WindowsPowerShell\v1.0\Modules”
Do this on both the Service Manager Management Server and Orchestrator server. Problem solved!
Hopefully, this solution will work for those of you who encountered the same issue as me.