I am using the following code to respond back with list of processes of a remote server:
processes = Get-WmiObject -Class win32_process -Namespace "rootcimv2" -ComputerName $hostname | Select name, Status
Since I outfile this in a JSON array, I receive the following:
"processes": [ { "name": "System Idle Process", "Status": null }, { "name": "System", "Status": null }, { "name": "smss.exe", "Status": null }, { "name": "csrss.exe", "Status": null }, {
Am I writing the code wrong? When I double check, it appears all of the listed processes are running.
Thank you!
submitted by /u/networkhappi
[link] [comments]
The post Does win32_process allow to query for “status” of said processes? Seems to be blank/null whenever I attempt it. appeared first on How to Code .NET.