Category Archives: Hyper-V

Working with VHD files and converting them

 

To get VHD file type information from hyper-v machines you can use this oneliner. It lists vhd and vhdx files within a folder structure and lists if the disk is Fixed or dynamic in size.

To convert the files from a fixed format to a dynamic format, use the information from the last command.

I use the same file and folder name as the original but add an text before.

I use this for servers that are decommissioned but I do not want to delete. This way, they use not a lot of storage space.

Access offline files (.wim, .vhd or .vhdx) using DISM

 

On the installation DVD of a Windows installation you find a file called install.wim. This file contains the complete installation of a new windows installation.

If you want to alter this installation you must use the DISM command. Deployment Image Servicing and Management (DISM.exe) is a command-line tool that can be used to service a Windows image or to prepare a Windows Preinstallation Environment (Windows PE) image. DISM can be used to service a Windows image (.wim) or a virtual hard disk (.vhd or .vhdx).

The steps for altering a file, in this case the install.wim file, follow these steps.

Read more »