【Amazon GWスマイルセール開催中】4/18(金) 9:00 ~ 4/21(月) 23:59まで限定!バッファローのWi-Fiルーターやスイッチングハブ、Xiaomiスマートウォッチ・タブレット・モニター、iPhone SE整備済み品など多数アイテムが最大19%OFF!

How to Use the Windows wmic Command | Easily Retrieve System and Hardware Information

目次

What is the wmic Command?

The wmic (Windows Management Instrumentation Command-line) command is a powerful tool in Windows that allows users to retrieve and manage system and hardware information via the command line. Using Windows Management Instrumentation (WMI), it provides detailed data on the OS, processes, hardware configuration, network settings, and more. It’s a valuable tool for system administrators and developers.

Main Uses

  • Retrieve system information: Obtain detailed information on CPU, memory, disk drives, network adapters, and more.
  • Manage processes and tasks: Check the status of running processes or stop/restart tasks when necessary.
  • Manage hardware: View detailed information on installed hardware, such as disk drives and memory modules.
  • Troubleshoot system issues: Use the information provided by wmic to identify and resolve hardware or system problems.

How to Use the wmic Command

https://twitter.com/tama_global/status/1848525468389282030

Running the wmic command opens an interactive WMI console. You can then use specific queries to retrieve system information.

Basic Syntax

wmic [Class Name] [Parameters]
  • Class Name: The system information category, such as cpu, os, diskdrive, etc.
  • Parameters: Specify the information or query conditions to retrieve.

Examples

  1. Retrieve CPU information
wmic cpu get name, maxclockspeed, status

This command retrieves the CPU name, maximum clock speed, and status, helping you check the processor’s performance or any errors.

  1. Display memory information
wmic memorychip get capacity, speed, manufacturer

Displays the capacity, speed, and manufacturer of installed memory chips, useful for checking memory specifications.

  1. Get OS information
wmic os get caption, version, buildnumber

This command shows the OS name, version, and build number, making it easy to verify the current system’s OS.

  1. Retrieve disk drive information
wmic diskdrive get model, size, status

Displays the model, size, and status of installed disk drives, helpful for checking disk capacity and health.

Key wmic Classes

The wmic command uses various classes to retrieve system information. Below are some key classes:

  1. cpu
wmic cpu get name, maxclockspeed, loadpercentage

Displays CPU name, maximum clock speed, and load percentage.

  1. memorychip
wmic memorychip get capacity, speed

Retrieves memory capacity and speed.

  1. diskdrive
wmic diskdrive get model, size, status

Displays disk drive model, size, and status.

  1. os
wmic os get caption, version, buildnumber

Displays OS name, version, and build number.

Practical Use Cases for wmic

1. Retrieve Complete System Information

wmic computersystem get model, manufacturer, numberofprocessors, totalphysicalmemory

This command provides a summary of the system’s overall configuration, including model, manufacturer, processor count, and physical memory. It’s useful for understanding the full system setup.

2. List All Running Processes

wmic process list brief

Displays a brief list of all running processes, helpful for managing tasks or troubleshooting system performance.

Important Considerations When Using the wmic Command

  • Administrator privileges required: Some wmic commands require administrator privileges. Be sure to run the command prompt as an administrator.
  • Deprecated in Windows 10 and later: The wmic command is deprecated in Windows 10 and beyond. Microsoft recommends using PowerShell commands like Get-WmiObject or Get-CimInstance as alternatives for newer system management tasks.

Conclusion

The wmic command is a highly effective tool for retrieving detailed information about system and hardware configurations in Windows. It’s especially useful for checking CPU, memory, and disk drives, and aids in troubleshooting. However, since wmic is deprecated in Windows 10 and later, consider using PowerShell alternatives like Get-WmiObject for future system management tasks.

Tamaglo

Thank you for reading!

執筆者:玉城 学(タマキ マナブ)

IT業界歴10年以上。ヘルプデスク・サーバーエンジニアとしてWindowsの設定、クラウド管理、PC最適化を担当。

現在はPC設定・Office活用の専門家として、ブログやYouTubeで情報を発信中。

詳しいプロフィールはこちら

SNSでも情報を発信しています: YouTubeTikTokInstagram

Comments

To comment


The reCAPTCHA verification period has expired. Please reload the page.

The maximum upload file size: 2 MB. You can upload: image. Links to YouTube, Facebook, Twitter and other services inserted in the comment text will be automatically embedded. Drop file here

目次