Answered by:
Connecting to remote serve failed with error: WinRM cannot process the request.

Question
-
Hi Experts
I am getting the below error when i am trying to execute a powershell script. i am trying to install a software on 20 servers and on all 20 servers i have local admin rights.
Invoke-command -ComputerName (get-content c:\list.txt) -filepath C:\soft.ps1
Connecting to remote server server01 failed with the following error message : WinRM cannot
process the request.
I am executing the powershell script from myjumpserver01 i have local admin rights on this server.
list.txt file contains server names in the below format
server01.contoso.com
server02.contoso.comExperts guide me on this
Saturday, April 18, 2020 8:54 PM
Answers
-
HI
1.If we run below command in command prompt (ran as admin)on myjumpserver01 ,will all 20 servers in trust list on myjumpserver01,can you check it?
Get-Item WSMan:\localhost\Client\TrustedHosts
For adding the remote server to trustshots like this
winrm set winrm/config/client '@{TrustedHosts="192.168.2.54,192.168.2.59"} '
2.there is a document for your reference
Remote Management with Server Manager
http://www.tuncaysahin.nl/remote-management-with-server-manager/
3.can you enter winver in command prompt on jump server and 20 servers then look the os version?
Best Regards
Andy YOU
Please remember to mark the replies as answers if they help.
If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.- Edited by Andy YOUMicrosoft contingent staff Monday, April 20, 2020 3:48 PM
- Proposed as answer by Andy YOUMicrosoft contingent staff Saturday, May 9, 2020 6:13 AM
- Marked as answer by Glenn Maxwell Wednesday, May 27, 2020 6:49 PM
Monday, April 20, 2020 3:36 PM
All replies
-
Follow https://stackoverflow.com/questions/18284132/winrm-cannot-process-the-request-fails-only-over-a-specific-domain
hth
MarcinSaturday, April 18, 2020 11:40 PM -
Check the status of " Windows Remote Management." service status from that servers and check following thread,
https://stackoverflow.com/questions/6587426/powershell-remoting-with-ip-address-as-target
Sunday, April 19, 2020 12:46 AM -
HI
1.If we run below command in command prompt (ran as admin)on myjumpserver01 ,will all 20 servers in trust list on myjumpserver01,can you check it?
Get-Item WSMan:\localhost\Client\TrustedHosts
For adding the remote server to trustshots like this
winrm set winrm/config/client '@{TrustedHosts="192.168.2.54,192.168.2.59"} '
2.there is a document for your reference
Remote Management with Server Manager
http://www.tuncaysahin.nl/remote-management-with-server-manager/
3.can you enter winver in command prompt on jump server and 20 servers then look the os version?
Best Regards
Andy YOU
Please remember to mark the replies as answers if they help.
If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.- Edited by Andy YOUMicrosoft contingent staff Monday, April 20, 2020 3:48 PM
- Proposed as answer by Andy YOUMicrosoft contingent staff Saturday, May 9, 2020 6:13 AM
- Marked as answer by Glenn Maxwell Wednesday, May 27, 2020 6:49 PM
Monday, April 20, 2020 3:36 PM