Using WMIC For Gathering System Info
WMIC is a command line interface to WMI (Windows Management Instrumentation). While it has many uses, I find it especially useful for querying certain system parameters.
Processor:
C:\>wmic cpu get Name Name
Intel(R) Pentium(R) M processor 1.80GHz
C:\>wmic cpu get NumberOfCores, NumberOfLogicalProcessors NumberOfCores NumberOfLogicalProcessors
1 1
The NumberOfCores and NumberOfLogicalProcessors properties are new to Windows Vista. NumberOfLogicalProcessor refers to the number of hyperthreading execution units that a processor has. NumberOfCores, to state the obvious, gets you the number of cores that a processor has.
Operating System:
C:\>wmic os get Name Name
Microsoftr Windows VistaT Ultimate |C:\Windows|\Device\Harddisk0\Partition1
C:\>wmic os get BuildNumber, BuildType, Version BuildNumber BuildType Version
6000 Multiprocessor Free 6.0.6000
C:\>wmic os get ServicePackMajorVersion, ServicePackMinorVersion ServicePackMajorVersion ServicePackMinorVersion
0 0
C:\>wmic os get OperatingSystemSKU
OperatingSystemSKU
1
The OperatingSystemSKU property is new to Windows Vista. A value of 1 means that you are running the Ultimate edition. Other values and their corresponding SKU names can be found on the Win32_OperatingSystem documentation page.
Finally, Windows Vista introduces the concept of Windows Experience Index that allows you to measure your PC’s performance. Your computer’s Windows Experience Index (WEI) score can be queried from command line. First we find out if the WEI score for your computer is still valid:
C:\>wmic path Win32_WinSAT get WinSATAssessmentState WinSATAssessmentState
1
A value of 1 for the property WinSATAssessmentState means that we have the correct, latest value of the WEI score available. A value other than 1 means that the score is either unknown or needs to be recomputed to be coherent with a hardware change made to the machine. Here is how you can get to the WEI scores:
C:\>wmic path Win32_WinSAT get CPUScore, D3DScore, DIskScore, GraphicsScore, MemoryScore, WinSPRLevel CPUScore D3DScore DiskScore GraphicsScore MemoryScore WinSPRLevel
3.7 2.5 3.8 2 4.1 2 From:http://www.deepakg.com/blog/2007/08/using-wmic-for-gathering-system-info/
Using WMIC For Gathering System Info的更多相关文章
- if __name__== "__main__" 的意思(作用)python代码复用
if __name__== "__main__" 的意思(作用)python代码复用 转自:大步's Blog http://www.dabu.info/if-__-name__ ...
- 每天写点python
1.收集系统信息python小程序 1 #!/usr/bin/env python 2 #A system information gathering script 3 4 import subpro ...
- DSET收集ESXi硬件日志
1.Open DSET CLI with administrator mode C:\Windows\system32>dellsysteminfo -s 10.125.1.xxx -u roo ...
- Python 创建函数和代码重用
1. cat func.py #!/usr/bin/python def func(): print "hello,this is a function" def func2(): ...
- Ubuntu16.04安装Ambari 2.7.3
概念了解 Ambair介绍 Apache Ambari是一个用于支持大数据软件供应 管理与监控软件.它也是一个分布式软件,分为Ambair-Server与Ambari-Client两个部分.在生产环境 ...
- 每天写点shell脚本 (持续更新)
1.显示系统信息脚本 #!/bin/bash #A system information gathering script #Command UNAME="uname -a" pr ...
- 牛掰的python与unix
python的中心哲学 Python 2.7.5 (default, Nov 6 2016, 00:28:07) [GCC 4.8.5 20150623 (Red Hat 4.8.5-11)] on ...
- 用python执行Linux命令
例1:在python中包装ls命令 #!/usr/bin/env python #python wapper for the ls command import subprocess subproce ...
- 强大的命令行工具wmic
1.wmic=Microsoft Windows Management Instrumentation 2. C:\WINDOWS\system32\wbem 下的东西,特别是.xsl格式化文件,实现 ...
随机推荐
- STC15?MSP430?ARM?DSP?
自从大学毕业以来,发现属于自己的时间越来越少,每天忙于工作,导致在大学学到的东西都好生疏,特别是大一刚开始学的模电,单片机等,现在才慢慢的抓起来,然后在这个多核处理器流行的时代,单片机貌似快过时了,但 ...
- [置顶] js模板方法的思路及实现
在js中如何实现设计模式中的模板方法? 思路的产生必然要求熟悉js,如何实现?就很简单了,都知道在js中如果定义两个相同名称的方法,前一个方法就会被后一个方法覆盖掉,使用此特点就可以实现模板方法. 例 ...
- EGit with eclipse to clone project from GitHub(Step by step)
转载请注明出处! 1. To find your project URL inside GitHub: watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQveWF ...
- Linux进程间通信总结
刚请完婚假,请假期间做了些技术总结,其中一个就是Linux进程间通信方式的总结. Linux提供了多种进程间通信的方式,列举如下: PIPE(管道) FIFO(先进先出,也称为有名管道) domain ...
- [置顶] 两主机搭建MySQL主从复制后,show slave status显示:Last_IO_Error: error connecting to master ……
两台主机A.B搭建mysql主从复制关系(A为master,B为slave)后,在slave上执行show slave status,结果中显示Last_IO_Error: error connect ...
- 解决spark运行中failed to locate the winutils binary in the hadoop binary path的问题
1.下载hadoop-common-2.2.0-bin并解压到某个目录 https://github.com/srccodes/hadoop-common-2.2.0-bin 2.设置hadoop.h ...
- https tomcat 证书搭建
首先生成证书说明 keytool -genkey -alias castest -keyalg RSA -keystore c:/keys/caskey 先让输入密码,密码必须记住,下面会用到 其中“ ...
- C文件操作(转载)
/*1.文件的打开(fopen函数)fopen函数用来打开一个文件,其调用的一般形式为:文件指针=fopen(文件名,文件操作方式):例如:FILE *fpinfpin=fopen("c:\ ...
- Ubuntu安装配置TFTP服务
tftpd-hpa 是一个功能增强的TFTP服务器.它提供了很多TFTP的增强功能,它已经被移植到大多数的现代UNIX系统. 1.安装 sudo apt-get install tftpd-hpa t ...
- TCP/IP笔记 四.应用层(1)——DNS
1. DNS DNS(Domain Name System ):域名系统,是因特网的一项核心服务,它作为可以将域名和IP地址相互映射的一个分布式数据库,能够使人更方便的访问互联网,而不用去记住能够被机 ...