Get-Process Won't Execute Remotely In Monitoring Script RRS feed

  • Question

  • In my workplace, we administer hospital intensive care PCs (Windows 7 desktop clients) that are meant to be on and running a particular program in near-perpetuity. To that end we've developed a few powershell scripts that run every 5 minutes and alert us whenever the PCs drop off the network or the processes / programs we require crash.

    Our program monitoring script relies on the powershell cmdlet "get-process" run remotely by an admin-credentialed account. The script works on all of our PCs except one and we haven't been able to determine what's causing the failure.

    At its most basic, the command looks something like 

        "get-process -computername [hostname]"

    When pointing toward our problem PC we get the error 

        "Get-Process : Couldn't connect to remote machine"

    Our research indicates that this is likely caused by permissions, firewall, or remote registry service problems. We've triple-checked and on this PC and 
    the monitoring account has admin privileges, no firewall is active, and remote registry service is on and set to start automatically. The code works when run on the local machine but not when run remotely.

    Similar powershell cmdlets run remotely, like "get-service", work with no issues. As noted above "get-process" runs successfully on our other PCs. Any insight into this strange issue would be appreciated.

    One thing to note is that the Invoke-Command workaround that has been offered in answer to other, similar questions doesn't work on this PC or any of our others.
    Tuesday, June 12, 2018 7:22 PM

All replies

  • This is not a PC support forum  or a break/fix forum.  You will need to contact someone to help you troubleshoot your network and PC.

    The most likely cause is with WMI.


    • Edited by jrv Tuesday, June 12, 2018 7:45 PM
    Tuesday, June 12, 2018 7:44 PM