WMIC实例

打开远程桌面

wmic PATH win32_terminalservicesetting WHERE (__Class!="") CALL SetAllowTSConnections 1


获取OS信息
wmic OS list status
wmic OS list system


wmic 获取进程名称以及可执行路径:
wmic process get name,executablepath


wmic 删除指定进程(根据进程名称):
wmic process where name="qq.exe" call terminate
或者用
wmic process where name="qq.exe" delete


添加的计划任务,wmic添加的同样AT命令也是可以看到
wmic job call create "sol.exe",0,0,true,false,********154800.000000+480
wmic job call create "sol.exe",0,0,1,0,********154600.000000+480

wmic 查看BIOS信息
wmic bios list full

wmic还有停止、暂停和运行服务的功能:
启动服务startservice,停止服务stopservice,暂停服务pauseservice。
具体的命令使用格式就是:
wmic Service where caption=”windows time” call stopservice
●--停止服务
wmic Service where caption=”windows time” call startservice
●--启动服务
wmic Service where name=”w32time” call stopservice
●--停止服务,注意name和caption的区别。
 

Service (Win32_Service)
WMIC SERVICE WHERE Caption="SSDP Discovery Service" CALL ChangeStartMode "Disabled"

原文地址:https://www.cnblogs.com/huqingyu/p/1734221.html