Powershellコマンドをリモートで実行すると少し混乱します。ServerAというテストサーバー(Win 2k8-R2-SP1)があり、PowerShellリモート処理が正しく有効になっています。私の開発マシン(Win 2k8-R2-SP1)から、PowerShellコマンドを正しくリモート実行できます。しかし、ServerB(Win 2k8-R2)という別のサーバーから同じコマンドを実行しようとすると、次のエラーが発生します。
[ServerA] Connecting to remote server failed with the following error message : The client cannot connect to the destination specified in the request. Verify that the service on the destination is running and is accepting requests. Consult the logs and documentation for the WS-Management service running on the destination, most commonly IIS or WinRM.
If the destination is the WinRM service, run the following command on the destination to analyze and configure the WinRM service: "winrm quickconfig". For more information, see the about_Remote_Troubleshooting Help topic.
+ CategoryInfo : OpenError: (:) [], PSRemotingTransportException
+ FullyQualifiedErrorId : PSSessionStateBroken
3台のマシンはすべて同じドメインにあります。私の混乱は、開発マシンからServerAに完全に接続してコマンドを実行できることです。
ServerBにSP1がないという事実は、違いを生むでしょうか?お知らせ下さい。3台すべてのサーバーで管理者権限を持つ同じドメインアカウントを使用しています。
そして、私が試しているコマンドはです
Invoke-Command -ComputerName ServerA -ScriptBlock {Get-UICulture}
。
助けてください。
ありがとう