Hi Glenn,
Thanks for the positive comment, I take pride in making elaborate scripts 🙂
First thing first, I have verified that the script runs, cause I can execute the script manually from a powershell prompt from the SRM "Recovery Node" Host while logged in as the user that the SRM process is running as. I've gone the extra step to even load the NetApp module in all powershell environments for this user by modifying the powershell $profile and adding "import-module DataOnTAP" unfortunately that still doesn't load the NetApp PS cmdlets when run via the Post PowerOn process.
From the extra logging that I've placed into the script and from the SRM execution logs I believe that the Netapp powershell commandlets aren't loading which causes the meat of the script to not function. I usually rely on logs to troubleshoot, unfortunately I do not see anything in the logs that I produce that show the "Import-Module DataOnTap" command failing. But I will test the "-EA" after the "Import-Module DataONTAP" to see if that produces any useful logs to see if that is what is causing my script to fail.
To answer you other question, I use the following syntax to run the script as a post Power-On recovery step.
C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe C:\WINDOWS\SRM\script.ps1
Thanks for the suggestion as I'm quite stumped by this.