When you send a remote command to a computer that is not enabled for Windows PowerShell remoting, the Windows Remote Management (WinRM) client times out and displays the following error message.

  Copy Code
The WinRM client cannot complete the operation within the time specified. Check if the machine name is valid and is reachable over the network and firewall exception for Windows Remote Management service is enabled.

To resolve the error, run the Enable-PSRemoting cmdlet on the remote computer. No configuration is required to enable a computer to send remote commands. However, computers must be configured to receive remote commands.

To enable Windows PowerShell remoting on a remote computer

  1. Connect to the remote computer by using a conventional method, such as Remote Desktop. You cannot use Windows PowerShell remoting yet.

  2. Run the Enable-PSRemoting cmdlet on the remote computer. The following command enables all required remote settings, enables the session configurations, and restarts the WinRM service to make the changes effective. At the Windows PowerShell prompt, type:

      Copy Code

    To suppress all user prompts while the computer is being configured for remoting, type:

      Copy Code
    enable-psremoting -force

See Also