VMware Cloud Community
sysCamel
Contributor
Contributor

VM with CDDrives connected

I want to list the name of my virtual machines that have CDDrive in connected state. I found a script to set them to off but I want to just list them and not change them.

0 Kudos
1 Reply
halr9000
Commander
Commander

Get-VM | Where-Object { (Get-CDDrive -VM $_).ConnectionState.Connected }






Author of the upcoming book: Managing VMware Infrastructure with PowerShell

Co-Host, PowerScripting Podcast (http://powerscripting.net)

My signature used to be pretty, but then the forum software broked it. vExpert. Microsoft MVP (Windows PowerShell). Author, Podcaster, Speaker. I'm @halr9000
0 Kudos