Script hangs when accessing remote machine

Welcome Forums General PowerShell Q&A Script hangs when accessing remote machine

Viewing 1 reply thread
  • Author
    Posts
    • #254717
      Participant
      Topics: 1
      Replies: 1
      Points: 12
      Rank: Member

      The below script just hangs with no error msg.

      Get-WmiObject -computername jaguar -Class Win32_Service -Filter “name=’XblGameSave'”

      I can access jaguar with ping and with Win10 file explorer. The same script executes fine when accessing 4 other machines on the same network.

      The PS version is 5 – minor version 1 – built 19041  – revision 1

      Any thoughts/help will be much appreciated – TIA, Joe

       

    • #254768
      Senior Moderator
      Topics: 9
      Replies: 1310
      Points: 4,789
      Helping Hand
      Rank: Community Hero

      Check Windows Management Framework, Windows firewall service is running or not. Mostly a server restart would fix this kind of issue with WMI. but its not a proper solution.

      You can do the same by using Invoke-Command as well.

Viewing 1 reply thread
  • You must be logged in to reply to this topic.