<?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 Running scripts in VSC-BackupJOB (4.2 &amp;amp; 5.0) in VMware Solutions Discussions</title>
    <link>https://community.netapp.com/t5/VMware-Solutions-Discussions/Running-scripts-in-VSC-BackupJOB-4-2-amp-5-0/m-p/75062#M7211</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i have to shutdown a vm in a customers environment, when the backup is running. The Workflow:&lt;/P&gt;&lt;P&gt;BackupJob Start:&lt;/P&gt;&lt;P&gt;1. Script will Shutdown VM&lt;/P&gt;&lt;P&gt;2. Script will wait 30 seconds (giving VM enough time to shutdown)&lt;/P&gt;&lt;P&gt;3. VSC will take snapshot&lt;/P&gt;&lt;P&gt;4. Script will Start VM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I built following Script:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if %BACKUP_PHASE% == PRE_BACKUP goto PRE&lt;/P&gt;&lt;P&gt;if %BACKUP_PHASE% == POST_BACKUP goto POST&lt;/P&gt;&lt;P&gt;goto END&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;:PRE&lt;/P&gt;&lt;P&gt;C:\WINDOWS\system32\windowspowershell\v1.0\powershell.exe -PSConsoleFile "C:\Program Files\VMware\Infrastructure\vSphere PowerCLI\vim.psc1" -Command "Connect-VIServer -Server 192.168.11.90; Get-Vm -Name "My-VM" | Shutdown-VMGuest -Confirm:$false"&lt;/P&gt;&lt;P&gt;timeout /T 30&lt;/P&gt;&lt;P&gt;goto END&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;:POS&lt;/P&gt;&lt;P&gt; C:\WINDOWS\system32\windowspowershell\v1.0\powershell.exe -PSConsoleFile "C:\Program Files\VMware\Infrastructure\vSphere PowerCLI\vim.psc1" -Command "Connect-VIServer -Server 192.168.11.90; Get-Vm -Name "My-VM" | Start-vm"&lt;/P&gt;&lt;P&gt;goto END&lt;/P&gt;&lt;P&gt;:END&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I save the script C:\Program Files\NetApp\Virtual Storage Console\smvi\server\scripts and selected it in my BackupJob. But it did not work. It seems that VirtualStorage Console is ignoring the script. No error message. Nothing. The BackupJob is successful, but VM is not in shutdown state...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyone ideas or tips?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 05 Jun 2025 05:32:44 GMT</pubDate>
    <dc:creator>PHILIP_SONNTAG</dc:creator>
    <dc:date>2025-06-05T05:32:44Z</dc:date>
    <item>
      <title>Running scripts in VSC-BackupJOB (4.2 &amp; 5.0)</title>
      <link>https://community.netapp.com/t5/VMware-Solutions-Discussions/Running-scripts-in-VSC-BackupJOB-4-2-amp-5-0/m-p/75062#M7211</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i have to shutdown a vm in a customers environment, when the backup is running. The Workflow:&lt;/P&gt;&lt;P&gt;BackupJob Start:&lt;/P&gt;&lt;P&gt;1. Script will Shutdown VM&lt;/P&gt;&lt;P&gt;2. Script will wait 30 seconds (giving VM enough time to shutdown)&lt;/P&gt;&lt;P&gt;3. VSC will take snapshot&lt;/P&gt;&lt;P&gt;4. Script will Start VM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I built following Script:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if %BACKUP_PHASE% == PRE_BACKUP goto PRE&lt;/P&gt;&lt;P&gt;if %BACKUP_PHASE% == POST_BACKUP goto POST&lt;/P&gt;&lt;P&gt;goto END&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;:PRE&lt;/P&gt;&lt;P&gt;C:\WINDOWS\system32\windowspowershell\v1.0\powershell.exe -PSConsoleFile "C:\Program Files\VMware\Infrastructure\vSphere PowerCLI\vim.psc1" -Command "Connect-VIServer -Server 192.168.11.90; Get-Vm -Name "My-VM" | Shutdown-VMGuest -Confirm:$false"&lt;/P&gt;&lt;P&gt;timeout /T 30&lt;/P&gt;&lt;P&gt;goto END&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;:POS&lt;/P&gt;&lt;P&gt; C:\WINDOWS\system32\windowspowershell\v1.0\powershell.exe -PSConsoleFile "C:\Program Files\VMware\Infrastructure\vSphere PowerCLI\vim.psc1" -Command "Connect-VIServer -Server 192.168.11.90; Get-Vm -Name "My-VM" | Start-vm"&lt;/P&gt;&lt;P&gt;goto END&lt;/P&gt;&lt;P&gt;:END&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I save the script C:\Program Files\NetApp\Virtual Storage Console\smvi\server\scripts and selected it in my BackupJob. But it did not work. It seems that VirtualStorage Console is ignoring the script. No error message. Nothing. The BackupJob is successful, but VM is not in shutdown state...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyone ideas or tips?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jun 2025 05:32:44 GMT</pubDate>
      <guid>https://community.netapp.com/t5/VMware-Solutions-Discussions/Running-scripts-in-VSC-BackupJOB-4-2-amp-5-0/m-p/75062#M7211</guid>
      <dc:creator>PHILIP_SONNTAG</dc:creator>
      <dc:date>2025-06-05T05:32:44Z</dc:date>
    </item>
  </channel>
</rss>

