<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Trouble running power shell script in ONTAP Discussions</title>
    <link>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39034#M9238</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;no, it WAS set to RemoteSigned and I changed it to Unrestricted.&amp;nbsp; This is because trying to run PS scripts in SMVI was giving me the error that scripts had to be signed.&amp;nbsp; However I still get the error when running the script under SMVI. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Sep 2010 14:47:25 GMT</pubDate>
    <dc:creator>findlay</dc:creator>
    <dc:date>2010-09-15T14:47:25Z</dc:date>
    <item>
      <title>Trouble running power shell script</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39025#M9236</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As the title. I'm having trouble running a power shell script as part of my pre-and post-smvi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I checked the log file, it says that the script cannot be loaded because the execution of scripts has been disabled on the system. I have gone into power shell and set the execution policy to be unrestricted yet I still get the same error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Under what user context does a script run when it is initiated by SMVI?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jun 2025 07:08:42 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39025#M9236</guid>
      <dc:creator>findlay</dc:creator>
      <dc:date>2025-06-05T07:08:42Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble running power shell script</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39030#M9237</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you sure you have set the execution policy to RemoteSigned&amp;nbsp; ?&lt;/P&gt;&lt;P&gt;1) Verify your Current setting -&amp;gt; PS C:\&amp;gt; Get-ExecutionPolicy&lt;/P&gt;&lt;P&gt;2) set to remotesigned -&amp;gt;&amp;nbsp; PS C:\&amp;gt; Set-ExecutionPolicy RemoteSigned (be sure to run, execute &lt;EM&gt;&lt;STRONG&gt;PowerShell as an Administrator&lt;/STRONG&gt;&lt;/EM&gt; &lt;EM&gt;to do this)&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt; &lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Philippe L.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Sep 2010 17:12:14 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39030#M9237</guid>
      <dc:creator>ple</dc:creator>
      <dc:date>2010-09-14T17:12:14Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble running power shell script</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39034#M9238</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;no, it WAS set to RemoteSigned and I changed it to Unrestricted.&amp;nbsp; This is because trying to run PS scripts in SMVI was giving me the error that scripts had to be signed.&amp;nbsp; However I still get the error when running the script under SMVI. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Sep 2010 14:47:25 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39034#M9238</guid>
      <dc:creator>findlay</dc:creator>
      <dc:date>2010-09-15T14:47:25Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble running power shell script: More info</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39039#M9240</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I’m trying to run a powershell script as part of my SMVI backup, but I keep getting the error&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;C:\Program Files (x86)\NetApp\SMVI\server\log\scripts&amp;gt;C:\Windows\System32\WindowsPowerShell\v1.0\powershell -file "C:\Program Files (x86)\NetApp\SMVI\server\scripts\shutdownAndSnapshotincDeletePostBackup.ps1"&lt;/P&gt;&lt;P&gt;File C:\Program Files (x86)\NetApp\SMVI\server\scripts\shutdownAndSnapshotincDe&lt;/P&gt;&lt;P&gt;letePostBackup.ps1 cannot be loaded because the execution of scripts is disable&lt;/P&gt;&lt;P&gt;d on this system. Please see "get-help about_signing" for more details.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; + CategoryInfo&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : NotSpecified: (:) [], ParentContainsErrorRecordE&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; xception&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; + FullyQualifiedErrorId : RuntimeException&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now google says that I have to set the execution policy to remotesigned, but it was already set to remotesigned so I set it to the even more lax unrestricted –&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Windows PowerShell&lt;/P&gt;&lt;P&gt;Copyright (C) 2009 Microsoft Corporation. All rights reserved.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS C:\Users\nbida&amp;gt; Get-ExecutionPolicy&lt;/P&gt;&lt;P&gt;Unrestricted&lt;/P&gt;&lt;P&gt;PS C:\Users\nbida&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have rebooted and still get the execution error. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In an effort to work out the context in which the script was running I issued an “echo %username%” command to a file and got&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;????&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Odd I thought, so I did a “SET” command to a file.&amp;nbsp; The output from the “set” command was –&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;???????????????????????????????????????????????????4??????????????????????????4?&lt;/P&gt;&lt;P&gt;?????????????????????????4????????????????????????????4?????????????????????????&lt;/P&gt;&lt;P&gt;??????????????4????????????????????????????4????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;????????????????????????????????????????????&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is obviously something wrong here, but I don’t know what it is.&amp;nbsp; Can anyone advise please?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Sep 2010 11:33:26 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39039#M9240</guid>
      <dc:creator>findlay</dc:creator>
      <dc:date>2010-09-17T11:33:26Z</dc:date>
    </item>
    <item>
      <title>Re: Trouble running power shell script</title>
      <link>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39044#M9243</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've finally found out what the problem is, so I thought I'd post it to help out others.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It seems that the change to executionPolicy in powershell is specific to the version of powershell in which you invoke the command, that's 32-bit or 64-bit.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I set the execution policy in 64-bit but SMVI was using the 32-Bit one to run the script, so the script was still trying to run in restricted mode.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;set the execution policy in 32-bit as well and now it runs. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Oct 2010 15:54:01 GMT</pubDate>
      <guid>https://community.netapp.com/t5/ONTAP-Discussions/Trouble-running-power-shell-script/m-p/39044#M9243</guid>
      <dc:creator>findlay</dc:creator>
      <dc:date>2010-10-26T15:54:01Z</dc:date>
    </item>
  </channel>
</rss>

