Tip: Find your Hyper-V Configuration File with PowerShell

See how you can use PowerShell to find your Hyper-V configuration files

Michael Otey

June 18, 2015

1 Min Read
Tip: Find your Hyper-V Configuration File with PowerShell

The Hyper-V Manager enables you to manage most aspects of Hyper-V VMs. However, one of the things that is not directly visible from the Hyper-V manager is the location of the Hyper-V configuration file. For Windows Server 2008, 2008 R2 and 2012 the Hyper-V configuration file is an xml file that has a rather unfriendly GUID name. You can see the default virtual machine location looking at the Hyper-V Settings and if you open the Hyper-V settings for the virtual machine you can see where the Checkpoints and Smart Paging files are stored but it’s quite possible that the configuration file may have been created somewhere else or moved to a different location. If you’re working on an unfamiliar host of a host where there has been no standardized placement of the VM assets you might find yourself wanting to know where your Hyper-V configuration files are located.  Fortunately, you can use the PowerShell Get-VM cmdlet to retrieve the location and name of your Hyper-V configuration files like you can see below.

$VM = Get-VM “MyVM”Write-Host $VM.ConfigurationLocationWrite-Host $VM.VMId

 

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like