Questions tagged [wmi]
Windows Management Instrumentation (WMI) is the infrastructure for management data and operations on Windows operating systems. It is based on Web-Based Enterprise Management (WBEM) and Common Information Model (CIM).
174
questions
1
vote
2
answers
1k
views
Set remote time via WMI (invoke Win32_OperatingSystem.SetDateTime())
The goal is to make XML/SOAP/WSMan request from Python and Linux and set time on remote Windows 10 machine.
I can do that via CMD, PowerShell or Cygwin/SSH but I need fast native way. I'm doing a lot ...
0
votes
1
answer
2k
views
How to close an instance of file explorer using python?
I have 3 instances of File Explorer running on my system. In the task manager, there is only a single process_id assigned to explorer.exe
So if i want to kill one particular instance of explorer ...
1
vote
0
answers
268
views
WMI script to adjust Speakers' Balance (Win7)
I would like to create a script that configures the Balance on my Speakers-- specifically I would like to call WMI (Windows Management Instrumentation) from a VBScript if possible. Is this adjustment ...
1
vote
1
answer
3k
views
wmic + powershell run a command to search and remove files
I want to clean a website before a deploy. In order to do that, I use WMIC to run remotely and Powershell to remove all the files except some specific ones:
WMIC /node:server /user:user /password:...
0
votes
1
answer
512
views
CIM_Battery WMI Class has no instances
I am trying to create a C# Application that records the battery percentage over time, and to do that I have been trying to use the .NET WMI API. I looked on MSDN and found that there is a WMI class ...
0
votes
0
answers
182
views
WmiPrvSE excess cpu on Windows 7 32bit [duplicate]
One of my desktops is running Windows 7 (32bit). I am seeing unexpectedly high CPU load for the WmiPrvSE process. Using ProcessExplorer, I can see that it is just one thread that is alternately ...
3
votes
1
answer
11k
views
Remote connect to a Windows via PowerShell in Linux
I'm trying to connect to a Windows Machine via PowerShell in a Linux Machine to get some system's info, but I need to achieve it without use the WinRm.
Firstly, I installed the PowerShell following ...
1
vote
0
answers
597
views
How to get last Windows update date of Server 2016 and Server 2012 R2 remotely?
I am attempting to automatically check the date Windows Updates were last installed on a Windows Server 2012 machine and a Server 2016 machine from a remote machine. I can't seem to find any ...
0
votes
1
answer
168
views
Setting an application height and width using WMI
Is it possible to set an application's height and width using WMI? If so, how?
For example, change the height and width of Notepad.
Thanks
2
votes
1
answer
6k
views
What are and where are located WMI database Entries?
Using autoruns from sysinternals, I found a suspect row in the tab 'VMI'
There is a Powerlog item, in the folder WMI Database Entries.
I clicked with right, and "Jump to Entry".
This opened my ...
0
votes
1
answer
5k
views
Windows 8.1: Tasklist: ERROR: Not found
When I run tasklist, I get this error.
>tasklist
ERROR: Not found
>where tasklist
C:\Windows\System32\tasklist.exe
>tasklist /?
TASKLIST [/S system [/U username [/P [password]]]]
...
4
votes
3
answers
23k
views
Can I turn off WMI service permanently?
I'm tired of seeing my laptop sporadically consume 100% disk usage and gigabytes of memory. Most of the time the problem is on "Windows Management Instrumentation" service. Beside disk I/O consumption,...
1
vote
2
answers
159
views
Bad file association in WMI repository
Windows 7 machine, and as far as I know, the only oddness about the system is what I mention below.
I deal with a whole lot of text files that have no extension, so a while back, I associated files ...
3
votes
1
answer
26k
views
Why is my monitor showing up as "Generic Non-PnP Monitor"?
This is a follow-up question to this one.
I'm running Windows 7 on a desktop PC with an 27" AOC monitor.
When I run the following wmic command to determine the model of my monitor:
wmic ...
0
votes
1
answer
1k
views
WMI: Win32_DiskDrive (get memory mapped address), to Win32_DeviceMemoryAddress?
How can I get the memory mapped device address for a disk drive starting with a disk enumerated by
PS C:\WINDOWS\system32> gwmi Win32_DiskDrive | fl *
I can use
PS C:\WINDOWS\system32> gwmi ...
2
votes
2
answers
1k
views
Get drive index using a batch file
I'm currently playing with VirtualBox and one of the things that annoy me with it is that you have to do such a workaround to get it to boot from USB. So I'm thinking of automating this with a batch ...
1
vote
0
answers
1k
views
Where are Win32_Product entries actually stored in Server2K12 or Win* variants?
What Windows database or data source does Win32_Product pull its information from, if not the registry? For example,
if(Get-WmiObject -Class Win32_Product -Filter "Name like '%PRODUCT%'") {
...
1
vote
0
answers
4k
views
WMI query local administrators including group members
I know how to fetch a list of local administrators on a remote machine via WMI:
wmic /Node:"ComputerName" path win32_groupuser where (groupcomponent="win32_group.name=\"administrators\",domain=\"...
0
votes
0
answers
725
views
Why does Hyper-V virtualization depend on Windows Management Instrumentation?
In this experiment I disabled and deleted the Windows Management Instrumentation service in Windows 10 Pro 64bit. Do not try with your working PC. Here are the steps::
Set dependency to only Remote ...
0
votes
0
answers
612
views
Disable a built-in microphone and webcam remotely
We have some laptops docked at certain places that my head people want disabled. I have used Get-WMIObject to pull the class Win32_PnpEntity and used the Devcon utility to disable the "internal ...
1
vote
2
answers
1k
views
What's difference between `Dism /Capture-Image` and `recimg -CreateImage` on Windows 8.1?
I'm trying to make sense of wimboot vs refresh. Can someone give a short answer to the following?
What's the difference between
Dism /Capture-Image
and
recimg -CreateImage
They both produce .wim ...
1
vote
1
answer
819
views
WMI Host Provider Credentials
Numerous times per hour, a user on the a domain is getting locked out by WmiPrvSE.exe. Digging into the Event Log on the server that is locking out the user, it shows that WmiPrvSE.exe is using ...
4
votes
0
answers
4k
views
WMI-Activity Event ID5858, ResultCode = 0x80041032 & DCOM Event 10010 timeout errors
I've been trying to eliminate two types of errors for about a month now. First are WMI Event 5858 result code: 0x80041032 and the Second are DCOM Event 10010 server timeout errors. Read 100s of ...
0
votes
1
answer
1k
views
How to find the BIOS serial number on Windows 98?
In Windows 10 I can use WMI, but it seems that Microsoft has removed this download from their website which supports Windows 98. I need to use it for a legacy project.
Any ideas, or other tool ...
0
votes
1
answer
2k
views
WMIC Query returning unexpected answer?
Apologies if this seems like a noob question...but I can't figure this out for the life of me. I'm using WQL to query WMI for the Dell BIOS version in a task sequence in SCCM. That WQL Query is below:
...
0
votes
1
answer
197
views
How to debug failed WMI logins
I can connect to the target machine using wbemtest, but when I try connecting using an application based on J-Interop with the same credentials, the connection fails. I'm trying to figure out why. I ...
0
votes
0
answers
634
views
E_ACCESSDENIED accessing WMI from scheduled task
In Powershell, I'm enumerating SQL databases as follows:
$SqlServers = @("SQL1", "SQL2") # SQL servers
foreach ($SqlServer in $SqlServers) {
$SqlBasePath = "SQLSERVER:\SQL\$SqlServer\"
foreach ($...
0
votes
0
answers
2k
views
Importing WMIC txt into csv or xlsx
I have a logon script that logs several pieces of information and does it for a per device basis and then pipes it to a txt with the file name Computer-Name-report.txt
The company has hundreds of ...
1
vote
0
answers
934
views
Get-WmiObject throws "Invalid access to memory location."
I'm trying to run the following PowerShell command under WinPE (Version 10.0.10586.0):
Get-WmiObject -Class Win32_ComputerSystem
But I get this error:
Get-WmiObject : Invalid access to memory ...
1
vote
0
answers
426
views
How to simulate or restore corrupted WMI (Windows Management Instrumentation)
After fixing a crash that was related to a corrupted WMI, I would like to validate my solution. The problem is, that I meanwhile rebuild the corrupted WMI using https://stackoverflow.com/a/6930421/...
2
votes
1
answer
3k
views
How to find a Bluetooth device's manufacturer
I am trying to get the Manufacturer information for any given Bluetooth device, such as this mouse:
I have tried WMI, and the best I got was "Microsoft"
I've searched through the registry, and the ...
2
votes
1
answer
625
views
Enabling DHCP via PowerShell results in 2 WiFi connections to same network
I have a VM on my network setup as a gateway that I use sometimes, while most of the time I just leave my PCs configured to use DHCP and just have everything go through the router. I had been swapping ...
3
votes
1
answer
668
views
Permission to query WMI
I have a project to remove admin rights from our users. An application we use, during upgrades, runs a query against WMI:
Namespace: root\Microsoft\sqlserver\computermanagement10
Class: ...
3
votes
2
answers
864
views
How can I get useful information from the Search Indexer perfomance counters?
I've been trying to figure out a way to get information on the indexing progress programmatically (how many files to go or "indexing complete"). I stumbled upon the class ...
1
vote
1
answer
5k
views
Determine what GPU is running through WMI
I am trying to write a python script for to figure out which GPU (dedicated or integrated) is currently running. I have managed to make it work so far by running dxdiag and parsing the output for the ...
0
votes
1
answer
3k
views
How to format a date field in powershell?
In this script, I can get the date for shortcuts, but is in YYYYMMDD (and time) format. I'm going for MM/dd/yyyy. I've tried several suggestions from the web, but all result in errors, maybe because ...
1
vote
0
answers
3k
views
Use WMIC to find open files of a process
Is there a way do get a list of open files for a process using WMIC?
Yes, there are sysinternals like HANDLE.EXE that can do this, but you have to get a copy, but more importantly if you are ...
2
votes
0
answers
2k
views
Can't get screen resolution through WMIC on fresh Windows 10 installation
Running wmic desktopmonitor get screenheight, screenwidth in Windows' command prompt should return my screen's height and width, however when running that command on my fresh Windows 10 install, no ...
0
votes
1
answer
1k
views
How to Reboot and shut down based on Windows Update Status
I am working on Schedule Tasks where I can reboot or shutdown my OS based on Windows Update status.
My Setup
Run this task weekly on login.
This task starts wuauclt.exe /detectnow /updatenow.
Then I ...
0
votes
0
answers
47
views
Accessing underlying object of SWbemObject instance [duplicate]
I'm using vbscript to interact with the WMI classes. I am querying the Win32_GroupUser class which is defined here https://msdn.microsoft.com/en-us/library/windows/desktop/aa394153%28v=vs.85%29.aspx.
...
3
votes
1
answer
1k
views
Complex wmi queries using execquery
In powershell I can do a query like
> get-wmiobject -query 'select * from win32_groupuser' | % {[wmi]$_.partcomponent|select domain,name,SID}
Which will list for each wmi, the domain, name and ...
2
votes
1
answer
2k
views
Getting SID from win32_groupuser
I am trying to get the SIDs of users and groups by querying
get-wmiobject -query 'select groupcomponent,partcomponent from win32_groupuser`
output:
__GENUS : 2
__CLASS : ...
1
vote
1
answer
3k
views
WMI Call to retrieve Physical Serial Number on HDD's
I'm trying to write a script that incorporates a retrieved Drive Serial Number for a report. So far I've just been trying to get a WMI call or really anything to even retrieve it in the first place
...
1
vote
1
answer
3k
views
wmic command returns no instance when accessing Win32_BaseBoard class
Why does Win32_BaseBoard return no instances in PowerShell?
wmic path "Win32_BaseBoard" get "Model"
1
vote
0
answers
7k
views
How to get laptop docking station serial number programmatically?
Is there are a way to get laptop docking station serial number programmatically? I assume it should be accessible via WMI, specifically via Win32_SystemEnclosure class but unable to come up with ...
1
vote
0
answers
710
views
WMI, VMWare: Wrong ChassisTypes from Win32_SystemEnclosure
On Windows 7 installation on VMWare, following WMI query:
Select ChassisTypes from Win32_SystemEnclosure
is returning 1 (Other), and not expected value 3 (Desktop). It returns correct type on HyperV ...
0
votes
1
answer
847
views
PowerShell WMI function call with multiple variable [closed]
I want to call a WMI method which is taking one string as input , one integer as input and one integer as output.
Here is the Current Example:
$obj=Get-WmiObject -class "class1" -namespace "space1" $...
1
vote
1
answer
1k
views
WMI performance monitors not available
On a Windows Server 2008 R2 Datacenter (Service Pack) I am trying to query the following counters, but getting the error 'Invalid Query' in wbemtest.exe
Win32_PerfRawData_PerfOS_Memory
...
2
votes
1
answer
6k
views
Powershell/WMI to map mounded drive device IDs to Volume Letter
Right now I am using these two WMI queries to get information about drives on a machine:
get-wmiObject -Class Win32_LogicalDisk -Namespace root\CIMV2
-Computername $name
get-wmiObject -Class ...
3
votes
2
answers
4k
views
Why am I not getting my logon session from a WMI query?
I'm writing a program one of whose functions is to get the current logon sessions on a Windows computer. It queries WMI for the current sessions with logon type 2 (interactive), logon type 10 (remote ...