Win32_ComputerSystem class
The Win32_ComputerSystem WMI class represents a computer system running Windows.
The following syntax is simplified from Managed Object Format (MOF) code and includes all of the inherited properties.
Syntax
class Win32_ComputerSystem : CIM_UnitaryComputerSystem
{
uint16 AdminPasswordStatus;
boolean AutomaticManagedPagefile;
boolean AutomaticResetBootOption;
boolean AutomaticResetCapability;
uint16 BootOptionOnLimit;
uint16 BootOptionOnWatchDog;
boolean BootROMSupported;
string BootupState;
string Caption;
uint16 ChassisBootupState;
string CreationClassName;
sint16 CurrentTimeZone;
boolean DaylightInEffect;
string Description;
string DNSHostName;
string Domain;
uint16 DomainRole;
boolean EnableDaylightSavingsTime;
uint16 FrontPanelResetStatus;
boolean InfraredSupported;
string InitialLoadInfo;
datetime InstallDate;
uint16 KeyboardPasswordStatus;
string LastLoadInfo;
string Manufacturer;
string Model;
string Name;
string NameFormat;
boolean NetworkServerModeEnabled;
uint32 NumberOfLogicalProcessors;
uint32 NumberOfProcessors;
uint8 OEMLogoBitmap[];
string OEMStringArray[];
boolean PartOfDomain;
sint64 PauseAfterReset;
uint16 PCSystemType;
uint16 PowerManagementCapabilities[];
boolean PowerManagementSupported;
uint16 PowerOnPasswordStatus;
uint16 PowerState;
uint16 PowerSupplyState;
string PrimaryOwnerContact;
string PrimaryOwnerName;
uint16 ResetCapability;
sint16 ResetCount;
sint16 ResetLimit;
string Roles[];
string Status;
string SupportContactDescription[];
uint16 SystemStartupDelay;
string SystemStartupOptions[];
uint8 SystemStartupSetting;
string SystemType;
uint16 ThermalState;
uint64 TotalPhysicalMemory;
string UserName;
uint16 WakeUpType;
string Workgroup;
};
Members
The Win32_ComputerSystem class has these types of members:
Methods
The Win32_ComputerSystem class has these methods.
| Method | Description |
|---|---|
| JoinDomainOrWorkgroup |
Adds a computer system to a domain or workgroup. |
| Rename |
Renames a local computer. |
| SetPowerState |
Not implemented. For more information about how to implement this method, see the SetPowerState method in CIM_UnitaryComputerSystem. |
| UnjoinDomainOrWorkgroup |
Removes a computer system from a domain or workgroup. |
Properties
The Win32_ComputerSystem class has these properties.
- AdminPasswordStatus
-
- Data type: uint16
- Access type: Read-only
System hardware security settings for administrator password status.
Value Meaning - 1 (0x1)
Disabled
- 2 (0x2)
Enabled
- 3 (0x3)
Not Implemented
- 4 (0x4)
Unknown
- AutomaticManagedPagefile
-
- Data type: boolean
- Access type: Read/write
If True, the system manages the page file.
Windows Server 2003, Windows XP, and Windows 2000: This property is not available. - AutomaticResetBootOption
-
- Data type: boolean
- Access type: Read/write
If True, the automatic reset boot option is enabled.
- AutomaticResetCapability
-
- Data type: boolean
- Access type: Read-only
If True, the automatic reset is enabled.
- BootOptionOnLimit
-
- Data type: uint16
- Access type: Read-only
Boot option limit is ON. Identifies the system action when the ResetLimit value is reached.
Value Meaning - 1 (0x1)
Reserved
- 2 (0x2)
Operating System
- 3 (0x3)
System Utilities
- 4 (0x4)
Do Not Reboot
- BootOptionOnWatchDog
-
- Data type: uint16
- Access type: Read-only
Type of reboot action after the time on the watchdog timer is elapsed.
Value Meaning - 1 (0x1)
Reserved
- 2 (0x2)
Operating System
- 3 (0x3)
System Utilities
- 4 (0x4)
Do Not Reboot
- BootROMSupported
-
- Data type: boolean
- Access type: Read-only
If True, indicates whether a boot ROM is supported.
- BootupState
-
- Data type: string
- Access type: Read-only
System is started. Fail-safe boot bypasses the user startup files—also called SafeBoot.
The following list contains the required values:
- "Normal boot"
- "Fail-safe boot"
- "Fail-safe with network boot"
- Caption
-
- Data type: string
- Access type: Read-only
Short description of the object—a one-line string. This property is inherited from CIM_ManagedSystemElement.
- ChassisBootupState
-
- Data type: uint16
- Access type: Read-only
Boot up state of the chassis.
Value Meaning - 1 (0x1)
Other
- 2 (0x2)
Unknown
- 3 (0x3)
Safes
- 4 (0x4)
Warning
- 5 (0x5)
Critical
- 6 (0x6)
Nonrecoverable
- CreationClassName
-
- Data type: string
- Access type: Read-only
Name of the first concrete class in the inheritance chain of an instance. You can use this property with other properties of the class to identify all instances of the class and its subclasses. This property is inherited from CIM_System.
- CurrentTimeZone
-
- Data type: sint16
- Access type: Read/write
- Qualifiers: Units (Minutes)
Amount of time the unitary computer system is offset from Coordinated Universal Time (UTC).
- DaylightInEffect
-
- Data type: boolean
- Access type: Read-only
If True, the daylight savings mode is ON.
- Description
-
- Data type: string
- Access type: Read-only
Description of the object.
- DNSHostName
-
- Data type: string
- Access type: Read-only
Name of local computer according to the domain name server (DNS).
Windows XP and Windows 2000: This property is not available. - Domain
-
- Data type: string
- Access type: Read-only
Name of the domain to which a computer belongs.
Note If the computer is not part of a domain, then the name of the workgroup is returned.
- DomainRole
-
- Data type: uint16
- Access type: Read-only
Role of a computer in an assigned domain workgroup. A domain workgroup is a collection of computers on the same network. For example, a DomainRole property may show that a computer is a member workstation. This property is inherited from CIM_ManagedSystemElement.
Value Meaning - 0 (0x0)
Standalone Workstation
- 1 (0x1)
Member Workstation
- 2 (0x2)
Standalone Server
- 3 (0x3)
Member Server
- 4 (0x4)
Backup Domain Controller
- 5 (0x5)
Primary Domain Controller
- EnableDaylightSavingsTime
-
- Data type: boolean
- Access type: Read/write
Enables daylight savings time (DST) on a computer. A value of True indicates that the system time changes to an hour ahead or behind when DST starts or ends. A value of False indicates that the system time does not change to an hour ahead or behind when DST starts or ends. A value of NULL indicates that the DST status is unknown on a system.
- FrontPanelResetStatus
-
- Data type: uint16
- Access type: Read-only
The following table lists the hardware security settings for the reset button on a computer.
Value Meaning - 0 (0x0)
Disabled
- 1 (0x1)
Enabled
- 2 (0x2)
Not Implemented
- 3 (0x3)
Unknown
- InfraredSupported
-
- Data type: boolean
- Access type: Read-only
If True, an infrared (IR) port exists on a computer system.
- InitialLoadInfo
-
- Data type: string
- Access type: Read-only
Data required to find the initial load device or boot service to request that the operating system start up. This property is inherited from CIM_UnitaryComputerSystem.
- InstallDate
-
- Data type: datetime
- Access type: Read-only
Object is installed. An object does not need a value to indicate that it is installed. This property is inherited from CIM_ManagedSystemElement.
- KeyboardPasswordStatus
-
- Data type: uint16
- Access type: Read-only
System hardware security settings for Keyboard Password Status.
Value Meaning - 0 (0x0)
Disabled
- 1 (0x1)
Enabled
- 2 (0x2)
Not Implemented
- 3 (0x3)
Unknown
- LastLoadInfo
-
- Data type: string
- Access type: Read-only
Array entry of the InitialLoadInfo property that contains the data to start the loaded operating system. This property is inherited from CIM_UnitaryComputerSystem.
- Manufacturer
-
- Data type: string
- Access type: Read-only
Name of a computer manufacturer.
Example: Adventure Works
- Model
-
- Data type: string
- Access type: Read-only
Product name that a manufacturer gives to a computer. This property must have a value.
- Name
-
- Data type: string
- Access type: Read-only
Key of a CIM_System instance in an enterprise environment. This property is inherited from CIM_ManagedSystemElement.
- NameFormat
-
- Data type: string
- Access type: Read-only
Computer system Name value that is generated automatically. The CIM_ComputerSystem object and its derivatives are top-level objects of the Common Information Model (CIM). They provide the scope for several components. Unique CIM_System keys are required, but you can define a heuristic to create the CIM_ComputerSystem name that generates the same name, and is independent from the discovery protocol. This prevents inventory and management problems when the same asset or entity is discovered multiple times, but cannot be resolved to one object. Using a heuristic is recommended, but not required.
The heuristic is outlined in the CIM V2 Common Model specification, and assumes that the documented rules are used to determine and assign a name. The NameFormat values list defines the order to assign a computer system name. Several rules map to the same value.
The CIM_ComputerSystem Name value that is calculated using the heuristic is the key value of the system. However, use aliases to assign a different name for CIM_ComputerSystem, which can be more unique to your company. This property is inherited from CIM_System.
The following list identifies the values for this property.
- "IP"
- "Dial"
- "HID"
- "NWA"
- "HWA"
- "X25"
- "ISDN"
- "IPX"
- "DCC"
- "ICD"
- "E.164"
- "SNA"
- "OID/OSI"
- "Other"
- NetworkServerModeEnabled
-
- Data type: boolean
- Access type: Read-only
If True, the network Server Mode is enabled.
- NumberOfLogicalProcessors
-
- Data type: uint32
- Access type: Read-only
Number of logical processors available on the computer.
You can use NumberOfLogicalProcessors and NumberOfProcessors to determine if the computer is hyperthreading. For more information, see Remarks.
Windows Server 2003, Windows XP, and Windows 2000: This property is not available. - NumberOfProcessors
-
- Data type: uint32
- Access type: Read-only
Number of physical processors currently available on a system. This is the number of enabled processors for a system, which does not include the disabled processors. If a computer system has two physical processors each containing two logical processors, then the value of NumberOfProcessors is 2 and NumberOfLogicalProcessors is 4. The processors may be multicore or they may be hyperthreading processors. For more information, see Remarks.
Windows Server 2003, Windows XP, and Windows 2000: Because the NumberOfLogicalProcessors property is not available, NumberOfProcessors indicates the number of logical processors available in the system. In the case of a computer system that has two physical processors each containing two logical processors, the value of NumberOfProcessors is 4. - OEMLogoBitmap
-
- Data type: uint8 array
- Access type: Read-only
List of data for a bitmap that the original equipment manufacturer (OEM) creates.
- OEMStringArray
-
- Data type: string array
- Access type: Read-only
List of free-form strings that an OEM defines. For example, an OEM defines the part numbers for system reference documents, manufacturer contact information, and so on.
- PartOfDomain
-
- Data type: boolean
- Access type: Read-only
If True, the computer is part of a domain. If the value is NULL, the computer is not in a domain or the status is unknown. If you unjoin the computer from a domain, the value becomes false.
Windows 2000 and Windows NT: This property is not available. - PauseAfterReset
-
- Data type: sint64
- Access type: Read-only
- Qualifiers: Units (Milliseconds)
Time delay before a reboot is initiated—in milliseconds. It is used after a system power cycle, local or remote system reset, and automatic system reset. A value of –1 (minus one) indicates that the pause value is unknown.
- PCSystemType
-
- Data type: uint16
- Access type: Read-only
Type of the computer in use, such as laptop, desktop, or Tablet.
Windows Server 2003, Windows XP, Windows 2000, Windows NT 4.0, and Windows Me/98/95: This property is not available.Value Meaning - 0 (0x0)
Unspecified
- 1 (0x1)
Desktop
- 2 (0x2)
Mobile
- 3 (0x3)
Workstation
- 4 (0x4)
Enterprise Server
- 5 (0x5)
Small Office and Home Office (SOHO) Server
- 6 (0x6)
Appliance PC
- 7 (0x7)
Performance Server
- 8 (0x8)
Maximum
- PowerManagementCapabilities
-
- Data type: uint16 array
- Access type: Read-only
Array of the specific power-related capabilities of a logical device. This property is inherited from CIM_LogicalDevice.
Value Meaning - 0 (0x0)
Unknown
- 1 (0x1)
Not Supported
- 2 (0x2)
Disabled
- 3 (0x3)
Enabled
The power management features are currently enabled, but the exact feature set is unknown or the information is unavailable.
- 4 (0x4)
Power Saving Modes Entered Automatically
The device can change its power state based on usage or other criteria.
- 5 (0x5)
Power State Settable
The SetPowerState method is supported. This method is found on the parent CIM_LogicalDevice class and can be implemented. For more information, see Designing Managed Object Format (MOF) Classes.
- 6 (0x6)
Power Cycling Supported
The SetPowerState method can be invoked with the PowerState parameter set to 5 (Power Cycle).
- 7 (0x7)
Timed Power-On Supported
The SetPowerState method can be invoked with the PowerState parameter set to 5 (Power Cycle) and Time set to a specific date and time, or interval, for power-on.
- PowerManagementSupported
-
- Data type: boolean
- Access type: Read-only
If True, device can be power-managed, for example, a device can be put into suspend mode, and so on. This property does not indicate that power management features are enabled currently, but it does indicate that the logical device is capable of power management. This property is inherited from CIM_UnitaryComputerSystem.
- PowerOnPasswordStatus
-
- Data type: uint16
- Access type: Read-only
System hardware security settings for Power-On Password Status.
Value Meaning - 0 (0x0)
Disabled
- 1 (0x1)
Enabled
- 2 (0x2)
Not Implemented
- 3 (0x3)
Unknown
- PowerState
-
- Data type: uint16
- Access type: Read-only
Current power state of a computer and its associated operating system. The power saving states have the following values: Value 4 (Unknown) indicates that the system is known to be in a power save mode, but its exact status in this mode is unknown; 2 (Low Power Mode) indicates that the system is in a power save state, but still functioning and may exhibit degraded performance; 3 (Standby) indicates that the system is not functioning, but could be brought to full power quickly; and 7 (Warning) indicates that the computer system is in a warning state and a power save mode. This property is inherited from CIM_UnitaryComputerSystem.
Value Meaning - 0 (0x0)
Unknown
- 1 (0x1)
Full Power
- 2 (0x2)
Power Save - Low Power Mode
- 3 (0x3)
Power Save - Standby
- 4 (0x4)
Power Save - Unknown
- 5 (0x5)
Power Cycle
- 6 (0x6)
Power Off
- 7 (0x7)
Power Save - Warning
- PowerSupplyState
-
- Data type: uint16
- Access type: Read-only
State of the power supply or supplies when last booted. The following list identifies the values for this property.
Value Meaning - 1 (0x1)
Other
- 2 (0x2)
Unknown
- 3 (0x3)
Safe
- 4 (0x4)
Warning
- 5 (0x5)
Critical
- 6 (0x6)
Nonrecoverable
- PrimaryOwnerContact
-
- Data type: string
- Access type: Read-only
Contact information for the primary system owner, for example, phone number, email address, and so on. This property is inherited from CIM_System.
- PrimaryOwnerName
-
- Data type: string
- Access type: Read-only
Name of the primary system owner. This property is inherited from CIM_System.
- ResetCapability
-
- Data type: uint16
- Access type: Read-only
If enabled, the value is 4 and the unitary computer system can be reset using the power and reset buttons. If disabled, the value is 3, and a reset is not allowed. This property is inherited from CIM_UnitaryComputerSystem.
Value Meaning - 1 (0x1)
Other
- 2 (0x2)
Unknown
- 3 (0x3)
Disabled
- 4 (0x4)
Enabled
- 5 (0x5)
Nonrecoverable
- ResetCount
-
- Data type: sint16
- Access type: Read-only
Number of automatic resets since the last reset. A value of –1 (minus one) indicates that the count is unknown.
- ResetLimit
-
- Data type: sint16
- Access type: Read-only
Number of consecutive times a system reset is attempted. A value of –1 (minus one) indicates that the limit is unknown.
- Roles
-
- Data type: string array
- Access type: Read/write
List that specifies the roles of a system in the information technology environment. This property is inherited from CIM_System.
- Status
-
- Data type: string
- Access type: Read-only
- Qualifiers: MaxLen (10)
Current status of an object. Various operational and nonoperational statuses can be defined. Operational statuses include: OK, Degraded, and Pred Fail, which is an element such as a SMART-enabled hard disk drive that may be functioning properly, but predicts a failure in the near future. Nonoperational statuses include: Error, Starting, Stopping, and Service, which can apply during mirror-resilvering of a disk, reloading a user permissions list, or other administrative work. Not all status work is online, but the managed element is not OK or in one of the other states. This property is inherited from CIM_ManagedSystemElement.
The following list identifies the values for this property.
- "OK"
- "Error"
- "Degraded"
- "Unknown"
- "Pred Fail"
- "Starting"
- "Stopping"
- "Service"
- SupportContactDescription
-
- Data type: string array
- Access type: Read-only
List of the support contact information for the Windows operating system.
- SystemStartupDelay
-
- Data type: uint16
- Access type: Read/write
- Qualifiers: Units (Seconds)
SystemStartupDelay is no longer available for use as of Windows Vista because Boot.ini is not used to configure system startup. Instead, use the BCD classes supplied by the Boot Configuration Data (BCD) WMI provider or the Bcdedit command.
Windows Server 2003, Windows XP, and Windows 2000: Time to delay before starting the Windows operating system—in seconds. You can use SystemStartupDelay with SystemStartupSetting and SystemStartupOptions to modify Boot.ini system startup settings. - SystemStartupOptions
-
- Data type: string array
- Access type: Read-only
SystemStartupOptions is no longer available for use as of Windows Vista because Boot.ini is not used to configure system startup. Instead, use the BCD classes supplied by the Boot Configuration Data (BCD) WMI provider or the Bcdedit command.
Windows Server 2003, Windows XP, and Windows 2000: List of the options for starting up the computer system running Windows. This property must have a value. You can use SystemStartupOptions with SystemStartupSetting and SystemStartupDelay to modify Boot.ini system startup settings. - SystemStartupSetting
-
- Data type: uint8
- Access type: Read/write
SystemStartupSetting is no longer available for use as of Windows Vista because Boot.ini is not used to configure system startup. Instead, use the BCD classes supplied by the Boot Configuration Data (BCD) WMI provider or the Bcdedit command.
Windows Server 2003, Windows XP, and Windows 2000: Index of the default startup profile. This value is calculated so that it usually returns 0 (zero), because at write-time the profile string is physically moved to the top of the list, which is how Windows NT determines the default value. You can use SystemStartupSetting with SystemStartupDelay and SystemStartupOptions to modify Boot.ini system startup settings. - SystemType
-
- Data type: string
- Access type: Read-only
System running on the Windows-based computer. This property must have a value.
The following list identifies some of the possible values for this property.
- "x64-based PC"
- "X86-based PC"
- "MIPS-based PC"
- "Alpha-based PC"
- "Power PC"
- "SH-x PC"
- "StrongARM PC"
- "64-bit Intel PC"
- "64-bit Alpha PC"
- "Unknown"
- "X86-Nec98 PC"
- ThermalState
-
- Data type: uint16
- Access type: Read-only
Thermal state of the system when last booted.
Value Meaning - 1 (0x1)
Other
- 2 (0x2)
Unknown
- 3 (0x3)
Safe
- 4 (0x4)
Warning
- 5 (0x5)
Critical
- 6 (0x6)
Nonrecoverable
- TotalPhysicalMemory
-
- Data type: uint64
- Access type: Read-only
- Qualifiers: Units (Bytes)
Total size of physical memory. Be aware that, under some circumstances, this property may not return an accurate value for the physical memory. For example, it is not accurate if the BIOS is using some of the physical memory. For an accurate value, use the Capacity property in Win32_PhysicalMemory instead.
Example: 67108864
For more information about using uint64 values in scripts, see Scripting in WMI.
- UserName
-
- Data type: string
- Access type: Read-only
Name of a user that is logged on currently. This property must have a value. In a terminal services session, UserName returns the name of the user that is logged on to the console—not the user logged on during the terminal service session.
Example: jeffsmith
- WakeUpType
-
- Data type: uint16
- Access type: Read-only
Event that causes the system to power up.
Value Meaning - 0 (0x0)
Reserved
- 1 (0x1)
Other
- 2 (0x2)
Unknown
- 3 (0x3)
APM Timer
- 4 (0x4)
Modem Ring
- 5 (0x5)
LAN Remote
- 6 (0x6)
Power Switch
- 7 (0x7)
PCI PME#
- 8 (0x8)
AC Power Restored
- Workgroup
-
- Data type: string
- Access type: Read/write
Name of the workgroup for this computer. If the value of the PartOfDomain property is False, then the name of the workgroup is returned.
Windows 2000 and Windows NT: This property is not available.
Remarks
To determine the total number of processor instances associated with a computer system object, use the Win32_ComputerSystemProcessor association class.
A Win32_ComputerSystem instance that has multiple physical processors has multiple Win32_Processor instances associated with it. If the value of NumberOfLogicalProcessors is greater than the value of NumberOfProcessors then the computer system is either a multicore system or has one or more processors enabled for hyperthreading. For more information, see the NumberOfLogicalProcessors and NumberOfCores properties and Remarks section in Win32_Processor.
Windows Server 2003 and Windows XP: A single-processor computer system with hyperthreading architecture has more than one Win32_Processor instance associated with it. You cannot distinguish a computer that is hyperthreading from a computer with multiple physical processors. For example, the value of NumberOfProcessors is 2 for both a hyperthreading computer and a computer with two physical processors.
Windows 2000, Windows NT 4.0, and Windows Me/98/95: Hyperthreading is not supported by the operating system. A computer system only has one processor associated with it.
The Win32_ComputerSystem class is derived from CIM_UnitaryComputerSystem.
Examples
You can find an example script that obtains operating system and processor data from Win32_ComputerSystem, Win32_Processor, and Win32_OperatingSystem in the Win32_Processor topic examples. For script code examples, see WMI Tasks for Scripts and Applications and the TechNet ScriptCenter Script Repository.
For more information and C++ code examples, see WMI C++ Application Examples.
Requirements
|
Minimum supported client | Windows 2000 Professional [desktop apps only] |
|---|---|
|
Minimum supported server | Windows 2000 Server [desktop apps only] |
|
Namespace |
\root\CIMV2 |
|
MOF |
|
|
DLL |
|
See also
Send comments about this topic to Microsoft
Build date: 11/19/2012
