2901 shaares
124 private links
124 private links
Option 2 - To Enable and Disable Hyper-V in PowerShell
-
Open an elevated PowerShell, and do step 2 or 3 below for what you want to do.
-
To Enable Hyper-V
A) In the elevated PowerShell window, copy and paste the command below, press Enter, and go to step 4 below. Note, If you do not use the -All switch, then you will not install the Hyper-V GUI Management Tools and Hyper-V Module for Windows PowerShell features.
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V –All
- To Disable Hyper-V
A) In the elevated PowerShell window, copy and paste the command below, press Enter, and go to step 4 below.
Disable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V-All
- Type Y and press Enter when prompted to restart the computer.