# Get-Process does not return all properties from remote PC

**URL:** <https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210>\
**Category:** PowerShell Help\
**Created:** [May 16, 2015, 8:52am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210 "2015-05-16T08:52:09Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeffrey-wagar](https://avatars.discourse-cdn.com/v4/letter/j/858c86/32.png) [@jeffrey-wagar](https://forums.powershell.org/u/jeffrey-wagar)\
**Post date:** [May 16, 2015, 8:52am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/1 "2015-05-16T08:52:09Z")

</div>

PS C:\> Get-Process -ComputerName FS1 successfully returns the list of running processes from that remote computer [FS1], yet other than the six default properties (VM, WS, CPU, Handles, ID, ProcessName) the remaining properties of every process are blank. I am logged into my workstation with a Domain Administrator account and had opened my PowerShell console with “Run as Administrator”.

If I walk over to FS1’s keyboard, open the PowerShell console, then type Get-Process, nearly all the properties have values.

Repeating those two steps on another remote computer, the same pattern occurs – all properties populated only if Get-Process is typed in a local console.

Enable-PSRemoting on the remote file server [FS1] does not cause the non-default process property fields to be populated.

PS C:\> Get-WmiObject Win32\_Process successfully returns the list of running processes from that remote computer [FS1], and nearly all the properties have values. Alas, some of the Get-Process properties I desire are not available through Get-WmiObject.

In summary, Get-Process does not return an “access error”, does return the complete list of running process, just no properties beyond the 6 default ones.

---

<div class="post-metadata">

**Author:** ![donj](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.powershell.org/donj/32/137_2.png) [@donj](https://forums.powershell.org/u/donj)\
**Post date:** [May 16, 2015, 9:00am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/2 "2015-05-16T09:00:26Z")

</div>

Get-Process uses DCOM, so I wouldn’t expect Remoting to have anything to do with it. And either WMI or CIM would probably be a better way of obtaining that information; DCOM is definitely a dicier protocol these days.

If you run:

```
Get-Process -ComputerName FS1 | Select *
```

Can you paste a sample of one process’ properties as displayed? And also paste the result of:

```
Get-Process -ComputerName FS1 | Get-Member
```

Please.

---

<div class="post-metadata">

**Author:** ![jeffrey-wagar](https://avatars.discourse-cdn.com/v4/letter/j/858c86/32.png) [@jeffrey-wagar](https://forums.powershell.org/u/jeffrey-wagar)\
**Post date:** [May 16, 2015, 10:26am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/3 "2015-05-16T10:26:02Z")

</div>

Thanks for your prompt reply!

Here is the first screenshot requested

PS C:\> Get-Process -Computername FS1 | Select \*

---

<div class="post-metadata">

**Author:** ![jeffrey-wagar](https://avatars.discourse-cdn.com/v4/letter/j/858c86/32.png) [@jeffrey-wagar](https://forums.powershell.org/u/jeffrey-wagar)\
**Post date:** [May 16, 2015, 10:27am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/4 "2015-05-16T10:27:17Z")

</div>

Here is the second [pair of] screenshots – could quite fit the long list on a single screen shot.

PS C:\> Get-Process -ComputerName FS1 | Get-Member

---

<div class="post-metadata">

**Author:** ![jeffrey-wagar](https://avatars.discourse-cdn.com/v4/letter/j/858c86/32.png) [@jeffrey-wagar](https://forums.powershell.org/u/jeffrey-wagar)\
**Post date:** [May 16, 2015, 10:30am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/5 "2015-05-16T10:30:57Z")

</div>

Here are a pair of screenshots, one from executing the Get-Process cmdlet remotely, the other locally. Why does the local cmdlet return the Path property of most processes while issuing that cmdlet remotely returns not a single Path property?

PS C:\> Get-Process | Select Path issued from the local keyboard of the computer named FS1

PS C:\> Get-Process -ComputerName FS1 | Select Path issued remotely from my administrator workstation, logged in with a Domain Administrator account, in a “Run As Administrator” PowerShell console

---

<div class="post-metadata">

**Author:** ![donj](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.powershell.org/donj/32/137_2.png) [@donj](https://forums.powershell.org/u/donj)\
**Post date:** [May 16, 2015, 11:19am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/6 "2015-05-16T11:19:37Z")

</div>

Yup, that’s about what I expected. Welcome to the world of DCOM, where everything’s inconsistent and undocumented. DCOM filtered through .NET, no less, which is even more fun. Try Get-Service that way, sometime - it actually relies on the Remote Registry Service running on the target, if you can believe it.

My suggestion would be to either:

A) Use Get-WmiObject

B) Use Get-CimInstance

C) Run Invoke-Command -computername FS1 -script { Get-Process }

The latter gets the command running locally and then serializes the results to send back to you - you’ll get something more like what you’re used to, albeit with no methods. For A) or B), what is it you’re not able to get?

---

<div class="post-metadata">

**Author:** ![jeffrey-wagar](https://avatars.discourse-cdn.com/v4/letter/j/858c86/32.png) [@jeffrey-wagar](https://forums.powershell.org/u/jeffrey-wagar)\
**Post date:** [May 16, 2015, 11:46pm UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/7 "2015-05-16T23:46:00Z")

</div>

I am giving another talk on how PowerShell can be used for detecting silent malware. To provide two examples, I intended to detect malware processes that label themselves in Windows Task Manager as a Shared Host process “Svchost” but whose Image path is not C:\Windows\System32\svchost.exe. Other malware leaves the Company & Description properties of their O/S process blank. So those three process properties are what I am trying to fetch using Get-Process. That cmdlet does so from a local console, but amazingly not through a remote call.

---

<div class="post-metadata">

**Author:** ![donj](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.powershell.org/donj/32/137_2.png) [@donj](https://forums.powershell.org/u/donj)\
**Post date:** [May 17, 2015, 1:54am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/8 "2015-05-17T01:54:24Z")

</div>

So… translation, you need to get the path of the executable, as well as the process name?

First, I can absolutely confirm that Get-Process also doesn’t return everything remotely - at least on every system I have. So this isn’t you. So now we need to find another way to get what you want.

But both Get-WmiObject and Get-CimInstance have the process name and path.

```
Get-WmiObject -computer DC -class Win32_Process -filter "name like '%svchost%'" |
Select-Object -prop Name,Path
```

Works fine for me. Is that not what you’re trying to do?

(and FWIW, nothing weird about DCOM is “amazing” to me anymore!)

---

<div class="post-metadata">

**Author:** ![jeffrey-wagar](https://avatars.discourse-cdn.com/v4/letter/j/858c86/32.png) [@jeffrey-wagar](https://forums.powershell.org/u/jeffrey-wagar)\
**Post date:** [May 19, 2015, 12:44am UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/9 "2015-05-19T00:44:04Z")

</div>

Based on your help, Don, this issue can be marked as resolved. Here is a summary of what our testing learned.

1. Get-WmiObject Win32\_Process and Get-CimInstance Win32\_Process both pull the path of the executable that launched a specific O/S process.
2. Get-Process can pull the path of the executable, and also a helpful descriptive field (Company/Publisher) not available through Get-WmiObject or Get-CimInstance
3. Get-Process -Computer name uses the legacy DCOM protocol to poll a remote computer, but does not return all the process properties, unfortunately the Path property is always blank.
4. Invoke-Command -ComputerName $targetComputer -ScriptBlock { Get-Process } uses the WinRM protocol and does return all process properties.

Hope the explanation helps others choose correctly.

---

<div class="post-metadata">

**Author:** ![dotnVo](https://avatars.discourse-cdn.com/v4/letter/d/4af34b/32.png) [@dotnVo](https://forums.powershell.org/u/dotnVo)\
**Post date:** [May 16, 2024, 8:45pm UTC](https://forums.powershell.org/t/get-process-does-not-return-all-properties-from-remote-pc/4210/10 "2024-05-16T20:45:15Z")

</div>

Closed on May 16, 2024, 8:45pm UTC


