Get All VHDX for All VMs with this PowerShell Script
Do you need a list of all virtual disks on a Hyper-V server? Simply run this PowerShell script and it will give you a list of all VHD and VHDX files that are connected to virtual machines in Hyper-V:
$MyVMs = Get-VM Foreach ($MyVM in $MyVMs) { $AllHardDrives = $MyVM.HardDrives Foreach ($HardDriveItem in $AllHardDrives) { $HardDriveItem.path | Get-VHD } }
Are you Still Using PowerShell Scripts to Back up Your Hyper-V Virtual Machines?
Why not try BackupChain instead? It is a full-featured, yet lightweight, customizable, and simple Hyper-V backup solution and includes many features that make PowerShell scripting for backups unnecessary.
The issue with PowerShell scripts is that they are difficult to manage in the long-term. Most often, there is no proper error handling and logging in place. In addition, there is no alert system in place when errors occur in automated scripts. All of that puts your server infrastructure unnecessarily at risk.
BackupChain is popular with IT professionals because it’s lightweight and can be customized to work exactly the way you need it. It backs up your VMs, disks, and files to various target media and provides excellent logging, reporting, and alert functionality. Simply download it today and give it a try.
Backup Software Overview
BackupChain Server Backup SoftwareDownload BackupChain
Cloud Backup
Backup VMware Workstation
Backup FTP
Backup VirtualBox
Backup File Server
Hyper-V Backup
Backup Hyper-VPopular
- Hyper-V Links, Guides, Tutorials & Comparisons
- Veeam Alternative
- How to Back up Cluster Shared Volumes
- DriveMaker: Map FTP, SFTP, S3 Site to a Drive Letter (Freeware)
Resources
- Free Hyper-V Server
- Remote Desktop Services Blog
- SCDPM Blog
- SCOM Blog
- V4 Articles
- Knowledge Base
- FAQ
- Sitemap
- Backup Education
- Archive 2024
- Archive 2022
- Archive 2021
- Archive 2020
- Archive 2018
- Archive 2017
- Archive 2016
- Archive 2015
- Archive 2014
- Archive 2013
- Hyper-V Scripts in PowerShell
- FastNeuron
- BackupChain (Greek)
- BackupChain (Deutsch)
- BackupChain (Spanish)
- BackupChain (French)
- BackupChain (Dutch)
- BackupChain (Italian)
Backup Software List
BackupChain
Veeam
Unitrends
Symantec Backup Exec
BackupAssist
Acronis
Zetta
Altaro
Windows Server Backup
Microsoft DPM
Ahsay
CommVault
IBM
Other Backup How-To Guides
- Volume Shadow Copy Service error EndPrepareSnapshots Cannot Find Anymore Diff Area
- How to Delete Hyper-V Backup Checkpoint That’s Stuck
- Slow Cluster Shared Volume–Tips to Speed Up CSV and Backups
- Windows Server 2025 Direct ISO Download Link
- What’s New In Windows Server 2012 and R2?
- How to Resize, Shrink, or Expand VHDX in Hyper-V
- 9 Editions of Windows Server 2012 Compared At a Glance
- Windows Server 2012 R2 and Windows 8.1 Backup Software
- Reboot a virtual machine in Hyper-V from the command line
- How to fix ‘Microsoft Hyper-V VSS Writer’ is in failed state, Writer Failure code: 0x800423f3
- Helpful Hyper-V Links
- Hyper-V Best Practices You Must Know
- Hyper-V Host Disk Backup, Physical Host and Virtual Machine Backup
- How to Fix: Folder name too long to delete
- How to Fix VSS Errors (Volume Shadow Copy Service Errors)
- Resolving VSS_WS_FAILED_AT_FREEZE Backup Errors
- The Ultimate Hyper-V PowerShell Commands Cheat Sheet
- How to fix: 0x800423f4, The writer experienced a non-transient error. If the backup process is retried, the error is likely to reoccur
- 8 Pros and Cons of Hyper-V Backup using USB External Drives
- How to Convert VHD Files to VHDX Disks in Hyper-V