windows:powershell:commands:get-ciminstance

Get-CimInstance / Get-WmiObject

OS Info

$ Get-CimInstance Win32_OperatingSystem
SystemDirectory     Organization BuildNumber RegisteredUser SerialNumber            Version
---------------     ------------ ----------- -------------- ------------            -------
C:\WINDOWS\system32              19631       tomoyan        00330-80000-00000-AA440 10.0.19631

Get-WmiObject 風に取得したいなら

$ Get-CimInstance Win32_OperatingSystem | Format-List
SystemDirectory : C:\WINDOWS\system32
Organization    :
BuildNumber     : 19631
RegisteredUser  : tomoyan
SerialNumber    : 00330-80000-00000-AA440
Version         : 10.0.19631

CPU Info

$ Get-CimInstance Win32_Processor | Format-List
Caption           : Intel64 Family 6 Model 58 Stepping 9
DeviceID          : CPU0
Manufacturer      : GenuineIntel
MaxClockSpeed     : 2401
Name              : Intel(R) Core(TM) i7-3517U CPU @ 1.90GHz
SocketDesignation : U3E1

Processor Info をすべて表示

$ Get-CimInstance Win32_Processor | Format-List -Property *
Availability                            : 3
CpuStatus                               : 1
CurrentVoltage                          : 8
DeviceID                                : CPU0
ErrorCleared                            :
ErrorDescription                        :
LastErrorCode                           :
LoadPercentage                          : 24
Status                                  : OK
StatusInfo                              : 3
AddressWidth                            : 64
DataWidth                               : 64
ExtClock                                : 100
L2CacheSize                             : 256
L2CacheSpeed                            :
MaxClockSpeed                           : 2401
PowerManagementSupported                : False
ProcessorType                           : 3
Revision                                : 14857
SocketDesignation                       : U3E1
Version                                 :
VoltageCaps                             :
Caption                                 : Intel64 Family 6 Model 58 Stepping 9
Description                             : Intel64 Family 6 Model 58 Stepping 9
InstallDate                             :
Name                                    : Intel(R) Core(TM) i7-3517U CPU @ 1.90GHz
ConfigManagerErrorCode                  :
ConfigManagerUserConfig                 :
CreationClassName                       : Win32_Processor
PNPDeviceID                             :
PowerManagementCapabilities             :
SystemCreationClassName                 : Win32_ComputerSystem
SystemName                              : CMON
CurrentClockSpeed                       : 1900
Family                                  : 0
OtherFamilyDescription                  :
Role                                    : CPU
Stepping                                :
UniqueId                                :
UpgradeMethod                           : 33
Architecture                            : 9
AssetTag                                : To Be Filled By O.E.M.
Characteristics                         : 252
L3CacheSize                             : 4096
L3CacheSpeed                            : 0
Level                                   : 6
Manufacturer                            : GenuineIntel
NumberOfCores                           : 2
NumberOfEnabledCore                     : 2
NumberOfLogicalProcessors               : 4
PartNumber                              : To Be Filled By O.E.M.
ProcessorId                             : BFEBFBFF000306A9
SecondLevelAddressTranslationExtensions : False
SerialNumber                            : To Be Filled By O.E.M.
ThreadCount                             : 4
VirtualizationFirmwareEnabled           : False
VMMonitorModeExtensions                 : False
PSComputerName                          :
CimClass                                : root/cimv2:Win32_Processor
CimInstanceProperties                   : {Caption, Description, InstallDate, Name…}
CimSystemProperties                     : Microsoft.Management.Infrastructure.CimSystemProperties

注意!: このコマンドは PowerShell 6 から非推奨になりました。
PowerShell Core 6.0 の重要な変更 - PowerShell | Microsoft Docs を参照のこと。

OS Info

$ Get-WmiObject Win32_OperatingSystem
SystemDirectory : C:\WINDOWS\system32
Organization    :
BuildNumber     : 19631
RegisteredUser  : tomoyan
SerialNumber    : 00330-80000-00000-AA440
Version         : 10.0.19631

CPU Info

$ Get-WmiObject Win32_Processor
Caption           : Intel64 Family 6 Model 58 Stepping 9
DeviceID          : CPU0
Manufacturer      : GenuineIntel
MaxClockSpeed     : 2401
Name              : Intel(R) Core(TM) i7-3517U CPU @ 1.90GHz
SocketDesignation : U3E1

Processor Info をすべて表示

$ Get-WmiObject Win32_Processor | Format-List -Property *
PSComputerName                          : localhost
RunspaceId                              : 5f5c9c5c-bd5a-4142-be3b-ac5ee48c9e3f
PSShowComputerName                      : False
__GENUS                                 : 2
__CLASS                                 : Win32_Processor
__SUPERCLASS                            : CIM_Processor
__DYNASTY                               : CIM_ManagedSystemElement
__RELPATH                               : Win32_Processor.DeviceID="CPU0"
__PROPERTY_COUNT                        : 57
__DERIVATION                            : {CIM_Processor, CIM_LogicalDevice, CIM_LogicalElement, CIM_ManagedSystemEleme
                                          nt}
__SERVER                                : CMON
__NAMESPACE                             : root\cimv2
__PATH                                  : \\CMON\root\cimv2:Win32_Processor.DeviceID="CPU0"
AddressWidth                            : 64
Architecture                            : 9
AssetTag                                : To Be Filled By O.E.M.
Availability                            : 3
Caption                                 : Intel64 Family 6 Model 58 Stepping 9
Characteristics                         : 252
ConfigManagerErrorCode                  :
ConfigManagerUserConfig                 :
CpuStatus                               : 1
CreationClassName                       : Win32_Processor
CurrentClockSpeed                       : 1900
CurrentVoltage                          : 8
DataWidth                               : 64
Description                             : Intel64 Family 6 Model 58 Stepping 9
DeviceID                                : CPU0
ErrorCleared                            :
ErrorDescription                        :
ExtClock                                : 100
Family                                  : 0
InstallDate                             :
L2CacheSize                             : 256
L2CacheSpeed                            :
L3CacheSize                             : 4096
L3CacheSpeed                            : 0
LastErrorCode                           :
Level                                   : 6
LoadPercentage                          : 13
Manufacturer                            : GenuineIntel
MaxClockSpeed                           : 2401
Name                                    : Intel(R) Core(TM) i7-3517U CPU @ 1.90GHz
NumberOfCores                           : 2
NumberOfEnabledCore                     : 2
NumberOfLogicalProcessors               : 4
OtherFamilyDescription                  :
PartNumber                              : To Be Filled By O.E.M.
PNPDeviceID                             :
PowerManagementCapabilities             :
PowerManagementSupported                : False
ProcessorId                             : BFEBFBFF000306A9
ProcessorType                           : 3
Revision                                : 14857
Role                                    : CPU
SecondLevelAddressTranslationExtensions : False
SerialNumber                            : To Be Filled By O.E.M.
SocketDesignation                       : U3E1
Status                                  : OK
StatusInfo                              : 3
Stepping                                :
SystemCreationClassName                 : Win32_ComputerSystem
SystemName                              : CMON
ThreadCount                             : 4
UniqueId                                :
UpgradeMethod                           : 33
Version                                 :
VirtualizationFirmwareEnabled           : False
VMMonitorModeExtensions                 : False
VoltageCaps                             :
  • windows/powershell/commands/get-ciminstance.txt
  • 最終更新: 2020/09/11 17:23
  • by ともやん