So today we hit that old chestnut of an issue , you go and try and Storage vMotion a load of VM’s, when you get an error you realise that they had CD Drives connected.

You have two options manually go through through each VM and unmap the drive or a quick bit of PowerCLI to solve the problem.

First we do a quick check of the VM’s and see whats connected and to what:

Get-VM | Where-Object {$_.PowerState –eq “PoweredOn”} | Get-CDDrive | FT Parent, IsoPath


If there are none that we require lets set them all to “No Media

Get-VM | Where-Object {$_.PowerState –eq “PoweredOn”} | Get-CDDrive | Set-CDDrive -NoMedia -Confirm:$False


There we go, we can now do the Storage vMotion’s without issues.