Subscribe
Accepted Solution

prevent Remove-Navol asking for confirmation

Command Remove-Navol ask for confirmation and stop the workflow with this error

Windows PowerShell is in NonInteractive mode. Read and Prompt functionality is not available

Is there a way to bypass that.

Help apprecied

francois

Re: prevent Remove-Navol asking for confirmation

Hi Francois,

Please use:

Remove-navol -Name <volume name>  -Confirm:0

Please make sure you make the volume offline before you remove it by doing the following:

Set-NaVol  <volume name> -Offline

-Sharu

Re: prevent Remove-Navol asking for confirmation

Hi,

Please follow the below standard syntax when removing the volume,

Set-NaVol -Name <vol-name> -Offline -ErrorAction stop

Remove-NaVol -Name  <vol-name> -Confirm:$false -ErrorAction stop

Warm Regards

Sivaprasad K