<?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 echo Y | in Microsoft Virtualization Discussions</title>
    <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9893#M471</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Thank You All&amp;nbsp; (Glenn,&amp;nbsp; Eric, and Beam)..&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN __jive_emoticon_name="happy" __jive_macro_name="emoticon" class="jive_macro jive_macro_emoticon" src="https://community.netapp.com/4.5.5/images/emoticons/happy.gif"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is so amaze how powershell can do .&amp;nbsp;&amp;nbsp; It turns my 45+ lines dos command into&amp;nbsp; just 3 statements &lt;SPAN __jive_emoticon_name="cool" __jive_macro_name="emoticon" class="jive_macro jive_macro_emoticon" height="1" src="https://community.netapp.com/4.5.5/images/emoticons/cool.gif" width="1"&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Charles&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 29 Sep 2011 14:46:27 GMT</pubDate>
    <dc:creator>CharlesYeung</dc:creator>
    <dc:date>2011-09-29T14:46:27Z</dc:date>
    <item>
      <title>echo Y |</title>
      <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9856#M465</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Anyone knows how to convert "echo Y |"&amp;nbsp; dos command in PowerShell?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Charles&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Jun 2025 06:44:43 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9856#M465</guid>
      <dc:creator>CharlesYeung</dc:creator>
      <dc:date>2025-06-05T06:44:43Z</dc:date>
    </item>
    <item>
      <title>echo Y |</title>
      <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9861#M466</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Without knowing what your trying to do, have you tried {'y' | your command.exe}.&amp;nbsp; Without detailes it's hard to telll why the pipline isn't working. If you tell us what your trying to do we can explore other options.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;~Glenn&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Sep 2011 03:39:02 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9861#M466</guid>
      <dc:creator>GlennSizemore</dc:creator>
      <dc:date>2011-09-29T03:39:02Z</dc:date>
    </item>
    <item>
      <title>echo Y |</title>
      <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9866#M467</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp; Glenn,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I am new to PowerShell..&amp;nbsp;&amp;nbsp;&amp;nbsp; What I am trying to do is piping&amp;nbsp; Echo Y | to Remove-NaSnapshot..&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The goal is to delete orphaned snapshot(s) from all the iSCSI volumes that start with {&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Example:&amp;nbsp; {93101811-e57c-4627-939a-46580448f181}&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;PS C:\Windows\system32&amp;gt; $VOLList = Get-NaVol&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;PS C:\Windows\system32&amp;gt; $myvar=”{*”&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;PS C:\Windows\system32&amp;gt; ForEach ($_.Name in $VOList) {Get-NaSnapshot $_.Name $myvar | Remove-NaSnapshot | write-host "Y"}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; Delete snapshot&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Are you sure you want to delete snapshot {93101811-e57c-4627-939a-46580448f181} from volume FFXCMGC01_SQL_DB?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;[Y] Yes&amp;nbsp; [A] Yes to All&amp;nbsp; [N] No&amp;nbsp; [L] No to All&amp;nbsp; [S] Suspend&amp;nbsp; [?] &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;PS C:\Windows\system32&amp;gt;&amp;gt;&amp;gt; ForEach ($_.Name in $VOLList) {Get-NaSnapshot $_.Name $myvar | Remove-NaSnapshot | echo Y}&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Delete snapshot&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Are you sure you want to delete snapshot {93101811-e57c-4627-939a-46580448f181} from volume FFXCMGC01_SQL_DB?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;[Y] Yes&amp;nbsp; [A] Yes to All&amp;nbsp; [N] No&amp;nbsp; [L] No to All&amp;nbsp; [S] Suspend&amp;nbsp; [?] Help (default is "Y"): y&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Delete snapshot&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Are you sure you want to delete snapshot {9b98763a-3e0a-4fd4-b40a-5129b787dd88} from volume FFXCMGC01_SQL_DB?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;[Y] Yes&amp;nbsp; [A] Yes to All&amp;nbsp; [N] No&amp;nbsp; [L] No to All&amp;nbsp; [S] Suspend&amp;nbsp; [?] Help (default is "Y"): y&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Thanks&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt;"&gt;Charles&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Sep 2011 11:32:03 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9866#M467</guid>
      <dc:creator>CharlesYeung</dc:creator>
      <dc:date>2011-09-29T11:32:03Z</dc:date>
    </item>
    <item>
      <title>Re: echo Y |</title>
      <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9870#M468</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Charles,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Great question!&amp;nbsp; Most PowerShell cmdlets (not just the toolkit) that prompt the user for confirmation have a "-Confirm" switch.&amp;nbsp; You can try something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_text_macro jive_macro_code"&gt;&lt;P&gt;Get-NaVol | Get-NaSnapshot -SnapName "{*" | Remove-NaSnapshot -Confirm&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Eric&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Sep 2011 12:49:16 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9870#M468</guid>
      <dc:creator>timothyn</dc:creator>
      <dc:date>2011-09-29T12:49:16Z</dc:date>
    </item>
    <item>
      <title>Re: echo Y |</title>
      <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9879#M469</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just to clarify, if you want to suppress the confirmation, you would use "-Confirm:$false":&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;Remove-NaSnapshot $volName $snapName -Confirm:$false&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also look into the $ConfirmPreference variable, which will control the confirmation prompt for all cmdlets.&amp;nbsp; The help topic about_Preference_Variables contains information about the $ConfirmPreference variable:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;help about_Preference_Variables&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps!&lt;/P&gt;&lt;P&gt;-Steven&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Sep 2011 13:13:57 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9879#M469</guid>
      <dc:creator>beam</dc:creator>
      <dc:date>2011-09-29T13:13:57Z</dc:date>
    </item>
    <item>
      <title>Re: echo Y |</title>
      <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9884#M470</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Ohh Eric so close &lt;SPAN __jive_emoticon_name="happy" __jive_macro_name="emoticon" class="jive_macro jive_emote" src="https://community.netapp.com/4.5.5/images/emoticons/happy.gif"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Charles, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PowerShell uses a series of common parameters to universally controll the behavior of all cmdlet.&amp;nbsp; Any cmdlet that prompts for confirmation is doing so by upgrading the -confirm switch.&amp;nbsp; You can inturn either, make any command prompt by adding the confirm switch as Eric did.&amp;nbsp; Or you can override it by supplying a negetive confirm value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Get-NaVol | Get-NaSnapshot -SnapName "{*"| Remove-NaSnapShot -confirm:$false&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for more information on how this all works just type "help about_commonparameters" from any powershell prompt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps, &lt;/P&gt;&lt;P&gt;~Glenn&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Sep 2011 13:18:48 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9884#M470</guid>
      <dc:creator>GlennSizemore</dc:creator>
      <dc:date>2011-09-29T13:18:48Z</dc:date>
    </item>
    <item>
      <title>echo Y |</title>
      <link>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9893#M471</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Thank You All&amp;nbsp; (Glenn,&amp;nbsp; Eric, and Beam)..&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN __jive_emoticon_name="happy" __jive_macro_name="emoticon" class="jive_macro jive_macro_emoticon" src="https://community.netapp.com/4.5.5/images/emoticons/happy.gif"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is so amaze how powershell can do .&amp;nbsp;&amp;nbsp; It turns my 45+ lines dos command into&amp;nbsp; just 3 statements &lt;SPAN __jive_emoticon_name="cool" __jive_macro_name="emoticon" class="jive_macro jive_macro_emoticon" height="1" src="https://community.netapp.com/4.5.5/images/emoticons/cool.gif" width="1"&gt;&lt;/SPAN&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Charles&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Sep 2011 14:46:27 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Microsoft-Virtualization-Discussions/echo-Y/m-p/9893#M471</guid>
      <dc:creator>CharlesYeung</dc:creator>
      <dc:date>2011-09-29T14:46:27Z</dc:date>
    </item>
  </channel>
</rss>

