Windows 10: Auto-Mount VHD or VHDX File at Startup in Windows 10

Discus and support Auto-Mount VHD or VHDX File at Startup in Windows 10 in Windows 10 Tutorials to solve the problem; How to: Auto-Mount VHD or VHDX File at Startup in Windows 10 How to Auto-Mount VHD or VHDX File at Startup in Windows 10 VHD (Virtual Hard Disk)... Discussion in 'Windows 10 Tutorials' started by Awa197, Jul 12, 2018.

  1. Awa197 Win User

    Auto-Mount VHD or VHDX File at Startup in Windows 10


    How to: Auto-Mount VHD or VHDX File at Startup in Windows 10

    How to Auto-Mount VHD or VHDX File at Startup in Windows 10


    VHD (Virtual Hard Disk) is a file format which represents a virtual hard disk drive (HDD). It may contain what is found on a physical HDD, such as disk partitions and a file system, which in turn can contain files and folders. It is typically used as the hard disk of a virtual machine.

    VHDX is a Hyper-V virtual hard disk file format. VHDX has a much larger 64 TB storage capacity than the older VHD format 2TB limit. It also provides data corruption protection during power failures and optimizes structural alignments of dynamic and differencing disks to prevent performance degradation on new, large-sector physical disks.

    When you .vhd or .vhdx file, it will be added as a drive in File Explorer > This PC to open it from.

    This tutorial will show you how to create an elevated task to auto-mount a VHD or VHDX file at startup for all users in Windows 8.1 and Windows 10.

    *note You must be signed in as an administrator to create an elevated task to auto-mount a VHD or VHDX file at startup.


    CONTENTS:
    • Option One: Create Elevated Task to Auto-Mount VHD or VHDX File at Startup
    • Option Two: Delete Elevated Task to Undo Auto-Mount VHD or VHDX File at Startup

    EXAMPLE: VHD or VHDX file mounted as drive in File Explorer > This PC

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]







    OPTION ONE [/i] Create Elevated Task to Auto-Mount VHD or VHDX File at Startup
    1. Press the Win+R keys to open the Run dialog, type taskschd.msc, and click/tap on OK to open Task Scheduler.

    2. Click/tap on Task Scheduler Library in the left pane of Task Scheduler, and click/tap on Create Task in the right Actions pane. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    3. In the General tab, type a name (ex: "Auto-Mount VHD at Startup") you want for this task. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    4. In the General tab, type a description (ex: "D:\VHD\Example.vhd") you want for this task. (see screenshot below)

    *note I like to use the full path of the VHD or VDHX file as a quick reference of which file the task is mounting.

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    5. In the General tab, select (dot) the Run whether user is logged on or not box. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    6. In the General tab, check the Run with highest privileges box. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    7. In the General tab, select Windows 10 in the Configure for drop down menu. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    8. Click/tap on the Triggers tab, and click/tap on the New button. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    9. Select At startup in the Begin the task drop down menu, and click/tap on OK. (see screenshot below)

    *tip If you would like to delay this task from running at startup for a bit before prompting for the BitLocker password to unlock the drive, you can check the Delay task for box, and select how long of a delay you want after startup before this task automatically runs.

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    10. Click/tap on the Actions tab, and click/tap on the New button. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    11. Type PowerShell in the Program/script field. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    12. Type the command below into the Add arguments field, and click/tap on OK. (see screenshot below)
    *Arrow Mount-VHD -Path "Full path of VHD or VHDX file"

    *note Substitute Full path of VHD or VHDX file in the command above with the actual full path of the VHD or VHDX file you want automatically mounted at startup.

    For example: Mount-VHD -Path "D:\VHD\Example.vhd"



    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    13. Verify the details are correct for the command and full path of the VHD or VHDX file. (see screenshot below)

    *note If it is not correct, click/tap on Edit, go back to step 12, and correct it.

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    14. Click/tap on the Conditions tab, uncheck the Start the task only if the computer is on AC power box, and click/tap on OK. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    15. When prompted, enter the password of your Windows 10 account, and click/tap on OK. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    16. You will now see this new task (ex: "Auto-Mount VHD at Startup") listed in the Task Scheduler Library. You can now close Task Scheduler if you like. (see screenshots below)

    *tip You can disable and enable this task as needed if you ever wanted to temporarily stop mounting this VHD or VHDX file at startup.

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]






    OPTION TWO [/i] Delete Elevated Task to Undo Auto-Mount VHD or VHDX File at Startup
    1. Press the Win+R keys to open the Run dialog, type taskschd.msc, and click/tap on OK to open Task Scheduler.

    2. Click/tap on Task Scheduler Library in the left pane of Task Scheduler. (see screenshot below step 3)

    3. Select the task (ex: "Auto-Mount VHD at Startup") you created using Option One in the middle pane, and click/tap on Delete in the right Actions pane.

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    4. Click/tap Yes to confirm. (see screenshot below)

    Auto-Mount VHD or VHDX File at Startup in Windows 10 [​IMG]

    5. You can now close Task Scheduler if you like.

    Related Tutorials

    :)
     
    Awa197, Jul 12, 2018
    #1
  2. Brink Win User

    Auto-Mount VHD or VHDX File at Startup in Windows 10  

    Good idea David. I added a tip for this under step 9 for any others that may want to delay this task.
     
    Brink, Oct 27, 2019
    #2
  3. DavidY Win User
    Create Elevated Task to Auto-Mount VHD or VHDX File at Startup

    I've been doing a slightly older version of this for years with Bitlocker-encrypted VHDs.
    As mentioned, it does prompt for a Bitlocker password on startup, but it is possible to miss the prompt.
    If that happens, I right-click the drive in File Explorer and select the option to Unlock Drive.
    I've also found that adding a slight delay to the auto-mount task (one of the options on the screenshot at step 9 above) means that I'm more likely to see the password prompt on my very old laptop.
     
    DavidY, Oct 27, 2019
    #3
  4. DavidY Win User

    Auto-Mount VHD or VHDX File at Startup in Windows 10

    DavidY, Oct 27, 2019
    #4
  5. Brink Win User
    Create Elevated Task to Auto-Mount VHD or VHDX File at Startup

    Hello David, *Smile

    This method basically just directly uses a newer PowerShell command with the elevated task instead of a separate script file. The PowerShell command is only supported in Windows 8.1 and Windows 10.
     
    Brink, Oct 27, 2019
    #5
  6. Mount or Unmount VHD or VHDX File in Windows 10


    Hi, and thanks for your reply.

    There is no problem with File Backups. It is the System Image Backup .vhdx file which I am trying to view, using it to mount a VHD (Drive MAuto-Mount VHD or VHDX File at Startup in Windows 10 :) which appears empty to File Manager. As you suggested I had a good look at the W7 tutorial for file mounting, and explored some of its links, but to no avail.

    I also tried to mount the VHD with Diskpart from elevated command prompt: Diskpart; select vdisk file=filename.vhdx; attach vdisk. There was no need to assign a drive letter as Windows remembered it, which is annoying. M: was again empty.

    Then, Windows PowerShell: Mount-VHD -Path "[location of vhd]". This cmdlet failed with error message "Mount-VHD is not recognised as the name of a cmdlet ...". Googling this, I found this could be due to the absence of a Hyper-V module for Windows PowerShell. Now, I know that Hyper-V Virtualization does not come with W10 Home but does with W10 Pro. Could my problem be related? Could it be that the image file is vdhx rather than vdh which I assume was the format in W7? I am out of my depth here, and don't want to experiment without advice.

    Out of interest I checked UEFI Bios and found Virtualisation Technology to be disabled, and Hyper-V missing from the Programs and Features list in Control Panel. With some trepidation I tried Enabling Virtualisation. Programs and Features list was unchanged, as was the PowerShell outcome and the zero content of M: after attaching via Disk Management. I returned Virtualisation to Disabled.

    Drive M:'s properties show its partition type to be GUID, not MBR.

    Grateful for any further thoughts. Thanks.
     
    Old Novice, Oct 27, 2019
    #6
Thema:

Auto-Mount VHD or VHDX File at Startup in Windows 10

Loading...
  1. Auto-Mount VHD or VHDX File at Startup in Windows 10 - Similar Threads - Auto Mount VHD

  2. How to Mount or Unmount VHD or VHDX (Virtual Hard Disk) File in Windows 10

    in Windows 10 News
    How to Mount or Unmount VHD or VHDX (Virtual Hard Disk) File in Windows 10: [ATTACH] [ATTACH]In this post, we will show you different ways using which you can natively mount or unmount VHD and VHDX virtual hard disk files in Windows 10. VHD and VHDX files cannot be mounted from removable media that isn’t formatted [...] This post How to Mount or...
  3. How to create and set up new VHD or VHDX File in Windows 10

    in Windows 10 News
    How to create and set up new VHD or VHDX File in Windows 10: [ATTACH] [ATTACH]Today, we will see how to create and set up (initialized and formatted) a new VHD and VHDX virtual hard disk file in Windows 10 using Disk Management. But before we begin, we will see what is a VHD and [...] This post How to create and set up new VHD or VHDX...
  4. How to BitLocker encrypt a VHD or VHDX Container file in Windows 10

    in Windows 10 News
    How to BitLocker encrypt a VHD or VHDX Container file in Windows 10: [ATTACH] [ATTACH]You can use BitLocker to encrypt a VHD or VHDX (Virtual Hard Disk) file mounted as a drive. In this post, we will show you how to create a portable BitLocker encrypted container file using a mounted VHD or VHDX [...] This post How to BitLocker encrypt a VHD...
  5. [SOLVED] Mount a VHD? How?

    in Windows 10 Drivers and Hardware
    [SOLVED] Mount a VHD? How?: I used VirtualBox to create a 640MB VHD (virtual hard disk) named 'Palemoon portable (Linux).vhd'. (Note that the VHD is not a VDI.) I need to format it, but first, I need to mount it. But when I attempt to mount it (as Administrator) via Disk Managment's 'Action' 'Attach...
  6. Mount a VHD? How?

    in Windows 10 Drivers and Hardware
    Mount a VHD? How?: I used VirtualBox to create a 640MB VHD (virtual hard disk) named 'Palemoon portable (Linux).vhd'. (Note that the VHD is not a VDI.) I need to format it, but first, I need to mount it. But when I attempt to mount it (as Administrator) via Disk Managment's 'Action' 'Attach...
  7. Bitlocker VHD not mounting

    in Windows 10 Network and Sharing
    Bitlocker VHD not mounting: When I try to mount my bitlocker-encrypted VHD file, I get the following error message: Couldn't Mount File, Make sure the file is in NTFS volume and isn't a compressed folder or volume When I previously and successfully mounted the vhd, I was prompted for the BitLocker...
  8. Create BitLocker Encrypted Container File with VHD or VHDX in Windows

    in Windows 10 Tutorials
    Create BitLocker Encrypted Container File with VHD or VHDX in Windows: How to: Create BitLocker Encrypted Container File with VHD or VHDX in Windows How to Create BitLocker Encrypted Container File with a VHD or VHDX File in Windows You can use BitLocker Drive Encryption to help protect your files on an entire drive. BitLocker can help...
  9. Create and Set Up New VHD or VHDX File in Windows 10

    in Windows 10 Tutorials
    Create and Set Up New VHD or VHDX File in Windows 10: How to: Create and Set Up New VHD or VHDX File in Windows 10 How to Create and Set Up New VHD or VHDX File in Windows 10 VHD (Virtual Hard Disk) is a file format which represents a virtual hard disk drive (HDD). It may contain what is found on a physical HDD, such as...
  10. Mount or Unmount VHD or VHDX File in Windows 10

    in Windows 10 Tutorials
    Mount or Unmount VHD or VHDX File in Windows 10: How to: Mount or Unmount VHD or VHDX File in Windows 10 How to Mount or Unmount VHD and VHDX File in Windows 10 VHD (Virtual Hard Disk) is a file format which represents a virtual hard disk drive (HDD). It may contain what is found on a physical HDD, such as disk...