Windows 10: Add or Remove Physical Hard Disk for Hyper-V Virtual Machine

Discus and support Add or Remove Physical Hard Disk for Hyper-V Virtual Machine in Windows 10 Tutorials to solve the problem; How to: Add or Remove Physical Hard Disk for Hyper-V Virtual Machine How to Add or Remove a Physical Hard Disk for Hyper-V Virtual Machine... Discussion in 'Windows 10 Tutorials' started by Kari, Jul 14, 2016.

  1. Kari Win User

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine


    How to: Add or Remove Physical Hard Disk for Hyper-V Virtual Machine

    How to Add or Remove a Physical Hard Disk for Hyper-V Virtual Machine


    Hyper-V enables running virtualized computer systems on top of a physical host. These virtualized systems (aka: guests) can be used and managed just as if they were physical computer systems, however they exist in a virtualized and isolated environment.

    Your Hyper-V virtual machines can also be connected to physical hard disks from the host computernot just to virtual hard disks. (This is sometimes referred to as having a pass-through disk connected to a virtual machine.)

    This tutorial will show you how to add and remove physical hard disks to access from a Hyper-V virtual machine in Windows 8 and Windows 10.


    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]
    Note editions.

    You can add hard drives (ex: HDD and SSD) and removable USB hard drives, but you will not be able to add removable media (ex: USB flash drive) to a Hyper-V virtual machine.

    While you have a physical hard disk added to a Hyper-V virtual machine, you will not be able to create a checkpoint for the virtual machine.


    CONTENTS:
    • Option One: To Add Physical Hard Disk to Hyper-V Virtual Machine
    • Option Two: To Remove Physical Hard Disk from Hyper-V Virtual Machine




    OPTION ONE [/i] To Add Physical Hard Disk to Hyper-V Virtual Machine
    1. Open Disk Management (diskmgmt.msc).

    2. Right click on the online disk (ex: Disk 3 - "Internal HDD") you want to add to the VM, and click/tap on Offline. (see screenshot below)

    *note It's required that the physical hard disk be in an offline state on the host computer to be able to add to the VM.

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    3. Once the disk is offline, you can close Disk Management if you like.

    4. Open the settings of the Hyper-V virtual machine you want to add the disk to. (see screenshots below)

    *note It doesn't matter if you currently have the virtual machine off or running.

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]


    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    5. In the VM's settings, click/tap on SCSI Controller in the left navigation pane, select Hard Drive on the right side, and click/tap on the Add button. (see screenshot below)

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    6. Select (dot) Physical hard disk on the right side, select the disk you want to add in the drop down menu, and click/tap on OK. (see screenshot below)

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    7. The disk will now be available to access in the virtual machine. (see screenshot below)

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]






    OPTION TWO [/i] To Remove Physical Hard Disk from Hyper-V Virtual Machine
    1. Open the settings of the Hyper-V virtual machine you want to remove the disk from. (see screenshots below)

    *note It doesn't matter if you currently have the virtual machine off or running.

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]


    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    2. In the VM's settings, select the disk you want to remove under SCSI Controller in the left navigation pane, and click/tap on the Remove button on the right side. (see screenshot below)

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    3. click/tap on OK. (see screenshot below)

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    4. The disk will now be removed from the virtual machine. (see screenshot below)

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    5. Open Disk Management (diskmgmt.msc).

    6. Right click on the offline disk (ex: Disk 3 - "Internal HDD") you removed from the VM, and click/tap on Online. (see screenshot below)

    *note You will need to set the disk back to an online state to be able to access it from your host computer again.

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]

    7. Once the disk is back online, you can close Disk Management if you like.

    That's it,
    Shawn


    Related Tutorials

    :)
     
  2. Andre Da Costa, Jul 14, 2016
    #2
  3. Hyper-V in Windows 10

    Well, its a Virtual Machine, you are not going to get the end to end experience as a physical host especially where graphics performance is concerned. Hyper-V in Windows 10 Pro is the same as Windows Server 2008 R2 and later as far functionality and hardware
    requirements.

    How
    to setup a virtual machine using Hyper-V
     
    Andre Da Costa, Jul 14, 2016
    #3
  4. Brink
    Brink New Member

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine

    Odd. The VM I used in the tutorial is a Gen 1 installation, and I didn't have any issue adding a physical hard disk while it was running. *Confused

    EDIT: Just to clarify, it doesn't matter if it's a Gen 1 or Gen 2 VM.


    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]
     
    Brink, Jul 14, 2016
    #4
  5. Kari Win User
    Really odd. I have to always add physical disks when vm is off. Screenshot from build 14388.
     
  6. Brink
    Brink New Member
    Let's see if others get the same error when running a Gen 1. It'll be interesting.
     
    Brink, Jul 14, 2016
    #6
  7. Kari Win User
    OK, case cleared *Smile

    I have never tried to add any other disks but one external disk I have, which I move from PC to PC to move data (mostly installers and ISO files) between virtual machines on different hosts. It's at least 6 or 7 years old WD disk and acts occasionally a bit strange, only connecting after several USB disconnect / reconnect cable tries. I can connect it on a running Gen. 2 vm but not on a running Gen. 1 vm.

    Now looking at my own screenshot about error adding synthetic disk I was thinking a real HDD is not synthetic! Connected another USB disk to running Gen. 1 vm without issues.

    You are right, I am wrong, it's that simple. The culprit in my case is not the running vm but a failing disk.

    Sorry *Smile
     
  8. Brink
    Brink New Member

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine

    Glad you found the culprit. I was wondering why it wouldn't work for you.
     
    Brink, Jul 14, 2016
    #8
  9. Kari Win User
    Thanks for a good tut *Smile
     
  10. cereberus Win User
    Thanks guys for a great tutorial. Pretty sure I know answer to this by my testing but just in case...

    VMWARE automatically takes a disk offline when it is added to a vm, and automatically puts it back online when vm is shutdown or suspended.

    Is it possible to do the same with Hyper-V as it is a but of a nuisance having to keep using disk management. Perhaps a powershell command where I could set up a shortcut if automatic is not possible?

    Edit - have setup a couple of simple one-click batch files using diskpart. Not as slick as vmware but a lot less hassle than using disk management..

    I know this is basic stuff for you guys but for benefit of other users:-

    file 1 - diskoffline.txt (on d:\ root drive in my case)

    select disk 1
    offline disk

    file 2 - diskoffline.cmd

    diskpart /s d:\diskoffline.txt

    Then create a shortcut for diskoffline.cmd file on desktop.

    Do same to put online as well.

    file 3 - diskonline.txt (on d:\ root drive in my case)

    select disk 1
    online disk

    file 4 - diskonline.cmd

    diskpart /s d:\diskonline.txt

    Then create a shortcut for diskonline.cmd file on desktop.

    When you get a popup notification asking what you to tap and select want to do with the drive, tap it and select no action. Then you do not see notification again.

    It does not require admin permission to do this, so you can just click the shortcuts.

    I am sure there are smarter ways of doing this but this is easy and works.
     
    cereberus, Jul 29, 2016
    #10
  11. Brink
    Brink New Member
    Brink, Jul 29, 2016
    #11
  12. cereberus Win User
    I am using enhanced mode but a gen 1 install - I will try gen 2.
     
    cereberus, Jul 29, 2016
    #12
  13. Kari Win User

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine

    Enhanced works exactly the same way in Gen 1 and Gen 2. You just need to click Show Options in Enhanced Mode dialog, and select the drives you want to access from vm:
    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]


    ... to see selected host drives in vm This PC:

    Add or Remove Physical Hard Disk for Hyper-V Virtual Machine [​IMG]
     
  14. Brink
    Brink New Member
    It works in both gen 1 and 2 as long as the Hyper-V virtual machine (guest) has Remote Desktop Services enabled and run Windows Server 2012 R2, Windows Server 2016, Windows 8.1, or Windows 10 as the guest operating system.
     
    Brink, Jul 29, 2016
    #14
  15. cereberus Win User
    Apologies Gents,

    I have enabled rdp in guest, but I cannot figure out how to get to the enhanced mode dialogue. I have the enhanced session set.

    edit: figured it out.
     
    cereberus, Jul 29, 2016
    #15
Thema:

Add or Remove Physical Hard Disk for Hyper-V Virtual Machine

Loading...
  1. Add or Remove Physical Hard Disk for Hyper-V Virtual Machine - Similar Threads - Add Remove Physical

  2. Hyper-V "Failed to Add Device 'Virtual Hard Disk' "

    in Windows 10 Network and Sharing
    Hyper-V "Failed to Add Device 'Virtual Hard Disk' ": Hyper-V is showing Error when I make Virtual Hard Disk. It can make Virtual Machine, expect for Hard Disk. I tried VHD./VHDX. but both not worked. [ATTACH]...
  3. Hyper V not connecting to virtual machine

    in Windows 10 BSOD Crashes and Debugging
    Hyper V not connecting to virtual machine: Suddenly, Hyper V would not connect to any Virtual Machine using the Virtual Machine Connection. I trying creating new VMs and nothing worked. I am using Windows 10 Education....
  4. Physical Machine not connected to Hyper-V systems

    in Windows 10 Network and Sharing
    Physical Machine not connected to Hyper-V systems: Hello Guys I have setup a lab on one standalone machine for Microsoft sccm. My base machine is having Windows 10 OS and not connected to outside Network. In Windows 10 Hyper-V i have build my Test DC with DHCP, SCCM Core server and two test machines. My Hyper-v machines...
  5. Hyper-V - Optimizing Virtual Machines

    in Windows 10 Tutorials
    Hyper-V - Optimizing Virtual Machines: How to: Hyper-V - Optimizing Virtual Machines Running Windows on a virtual machine can naturally never be as fast as same version of Windows on same computer running on physical hardware. However, by tweaking virtual machine settings, you can greatly impact the speed and...
  6. Hyper-V Nested Virtualization: Run virtual machines on virtual machine

    in Windows 10 Tutorials
    Hyper-V Nested Virtualization: Run virtual machines on virtual machine: How to: Hyper-V Nested Virtualization: Run virtual machines on virtual machine [img] Information Nested Virtualization means that user can enable Hyper-V on existing virtual machines, and run virtual machines and Windows Sandbox on them. To make Nested Virtualization...
  7. Slow writing to physical disks in Hyper-V

    in Windows 10 Virtualization
    Slow writing to physical disks in Hyper-V: If I copy a file from C drive in a hyper-v install to a separate partition on the vhd, I get approx 100MB/s which is pretty much the maximum hdd speed that contains the vhd. However, when I copy a file to an external physical drive, it is very slow @ approx 5 MB/s. Any...
  8. Backing up Hyper-V Virtual Machines

    in Windows 10 Virtualization
    Backing up Hyper-V Virtual Machines: Hi, I was wondering if all I really need to do to backup activated virtual machines but not associated virtual hard drives is just to copy the virtual hard drive folder to another drive (or even one drive) . All I am really interested is in saving the machines which have...
  9. Virtual Hard disk created in hyper-v

    in Windows 10 Virtualization
    Virtual Hard disk created in hyper-v: Hi There I am using windows 10 Pro, and had a virtual machine installed using Hyper-V with two virtual HDD in that VM. Recently I had some problem with my Windows 10 OS and had to reset my windows with keeping all the files and settings, and it installed a new windows...
  10. Remove Floppy Disk Drive in Windows Hyper-V Virtual Machine

    in Windows 10 Tutorials
    Remove Floppy Disk Drive in Windows Hyper-V Virtual Machine: How to: Remove Floppy Disk Drive in Windows Hyper-V Virtual Machine How to Remove Floppy Disk Drive in Windows Hyper-V Virtual Machine Hyper-V enables running virtualized computer systems on top of a physical host. These virtualized systems (aka: guests) can be used and...
Tags: