Get-CDROMDrive
Description
Get-CDROMDrive will provide you the information of a CD-ROM drive on a computer system running Windows.
Note: You need to install SysInfo module in order for this cmdlet to be available. For more information, see PowerShell Module SysInfo.
Syntax:
Get-CDROMDrive [[-ComputerName] <String[]>] [[-Protocol] <String>] [[-Properties] <String[]>] [<CommonParameters>]
Requirements
- SysInfo PowerShell Module
- WinRM Enabled and PowerShell 3.0 (only if you use WinRM protocol)
If you want to find more about the specific cmdlet while you are in PowerShell you can use the below to get the help file.
Code:
Get-Help Get-CDROMDrive
Output:
Now lets see few examples about Get-CDROMDrive
.
[adinserter name=”In Article”]
Examples
Example 1
This command gets the information from local system.
PS C:\> Get-CDROMDrive Caption : hp DVD-RAM GHA3N Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD Writer SystemName : LOCALPC
Example 2
This command gets the information from Server1.
PS C:\> Get-CDROMDrive -ComputerName Server1 Caption : Microsoft Virtual DVD-ROM Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD-ROM SystemName : Server1
Example 3
This command gets the information from remote system with IP 192.168.0.5.
PS C:\> Get-CDROMDrive -ComputerName "192.168.0.5" Caption : Microsoft Virtual DVD-ROM Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD-ROM SystemName : Server1
Example 4
This command gets the information from Server1, Server2 and Server3.
PS C:\> Get-CDROMDrive -ComputerName Server1,Server2,Server3 Caption : Microsoft Virtual DVD-ROM Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD-ROM SystemName : Server1 Caption : Msft Virtual CD/ROM ATA Device Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD-ROM SystemName : Server3 Caption : Msft Virtual CD/ROM ATA Device Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD-ROM SystemName : Server2
Example 5
This command gets the information from Server1 and will output only Name and Status Properties.
PS C:\> Get-CDROMDrive -ComputerName Server1 -Properties Name,Status Name Status ---- ------ Microsoft Virtual DVD-ROM OK
Example 6
This command gets the information from Server1 and will output all properties.
PS C:\> Get-CDROMDrive -ComputerName Server1 -Properties * Caption : Microsoft Virtual DVD-ROM Description : CD-ROM Drive InstallDate : Name : Microsoft Virtual DVD-ROM Status : OK Availability : Running or Full Power ConfigManagerErrorCode : ConfigManagerUserConfig : False DeviceID : SCSI\CDROM&VEN_MSFT&PROD_VIRTUAL_DVD-ROM\000001 ErrorCleared : ErrorDescription : LastErrorCode : PowerManagementCapabilities : PowerManagementSupported : StatusInfo : SystemName : Server1 Capabilities : {3, 7} CapabilityDescriptions : {Random Access, Supports Removable Media} CompressionMethod : Unknown DefaultBlockSize : ErrorMethodology : MaxBlockSize : MaxMediaSize : MinBlockSize : NeedsCleaning : NumberOfMediaSupported : Drive : D: DriveIntegrity : FileSystemFlags : FileSystemFlagsEx : Id : D: Manufacturer : (Standard CD-ROM drives) MaximumComponentLength : MediaLoaded : False MediaType : DVD-ROM MfrAssignedRevisionLevel : 1.0 RevisionLevel : SCSIBus : 0 SCSILogicalUnit : 1 SCSIPort : 0 SCSITargetId : 0 SerialNumber : Size : TransferRate : -1 VolumeName : VolumeSerialNumber :
Example 7
This command gets the information from Server1.
PS C:\> "Server1" | Get-CDROMDrive Caption : Microsoft Virtual DVD-ROM Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD-ROM SystemName : Server1
Example 8
This command gets the information from Server1 using DCOM protocol.
PS C:\>Get-CDROMDrive -ComputerName Server1 -Protocol DCOM Caption : Microsoft Virtual DVD-ROM Drive : D: Manufacturer : (Standard CD-ROM drives) VolumeName : MediaType : DVD-ROM SystemName : Server1
[adinserter name=”In Article”]
Optional Parameters
-ComputerName
- Description: Specifies the computer names or IP Addresses of the systems that we want to get the information from.
- Required: False
- Position: 1
- Default value: None
- Accept pipeline input: True (ByValue)
- Accept wildcard characters: False
-Protocol
- Description: Specifies the protocol that will be used to get the information from the remote system.
- Accepted Values: DCOM or WinRM
- Required: False
- Position: 2
- Default value: None
- Accept pipeline input: False
- Accept wildcard characters: False
-Properties
- Description: Specifies the object properties that appear in the display and the order in which they appear. Wildcards are permitted.
- Required: False
- Position: 3
- Default value
- Accept pipeline input: False
- Accept wildcard characters: True
Inputs
System.Array.
Get-CDROMDrive can accept a string value to determine the ComputerName parameter.
Outputs
System.Object.
Get-CDROMDrive returns an object containing all the information that has been retrieved.
[adinserter name=”In Article”]
Related Links
- Get-1394Controller
- Get-BaseBoard
- Get-Battery
- Get-BIOS
- Get-Bus
- Get-CacheMemory
- Get-CompactDisc
- Get-Desktop
- Get-DesktopMonitor
- Get-DiskDrive
- Get-DiskPartition
- Get-Fan
- Get-FloppyController
- Get-FloppyDrive
- Get-GlidePoint
- Get-HeatPipe
- Get-IDEController
- Get-InfraredDevice
- Get-Keyboard
- Get-LocalDisk
- Get-LogicalDisk
- Get-MemoryArray
- Get-MemoryDevice
- Get-MotherboardDevice
- Get-Mouse
- Get-NetworkAdapter
- Get-NetworkAdapterConfiguration
- Get-NetworkDrive
- Get-OperatingSystem
- Get-OpticalSensor
- Get-PhysicalMemory
- Get-PhysicalMemoryArray
- Get-PointingDevice
- Get-PortableBattery
- Get-PrinterConfiguration
- Get-PrinterInfo
- Get-Processor
- Get-RAMDisk
- Get-Refrigeration
- Get-RemovableDisk
- Get-SCSIController
- Get-SoundDevice
- Get-SystemEnclosure
- Get-TapeDrive
- Get-TemperatureProbe
- Get-TouchPad
- Get-TouchScreen
- Get-TrackBall
- Get-TrackPoint
- Get-USBController
- Get-VideoController
- Get-VoltageProbe
- PowerShell Gallery | SysInfo
- GitHub – SConstantinou/SysInfo
- PowerShell Module SysInfo
[adinserter name=”Matched-Content”]


Leave a Reply