【问题标题】:PowerShell enter-pssessionPowerShell 输入会话
【发布时间】:2014-10-23 07:32:48
【问题描述】:

我使用的是 Windows 8.1。我正在尝试在另一个 Windows 8.1 上执行命令。通过使用 PowerShell(enter-pssession 或 invoke-command)。我通常有两种类型的错误消息:一种告诉我访问被拒绝,另一种告诉我我的防火墙不允许 HTTPS 异常。没有一台计算机是服务器。我已经尝试执行 Set-PSSessionConfiguration -ShowSecurityDescriptorUI -Name Microsoft.PowerShell 没有任何结果。

我已经尝试停用我的防火墙,并且已经将其他计算机添加到我的受信任主机列表中。

我总是在 enter-pssession 后面加上一个 IP 地址。这可能是问题的根源吗?

提前致谢:)

附:两台电脑都有winrm、IIS和Apache。

【问题讨论】:

  • 您是否在要访问的主机上的 Windows 防火墙中为 PowerShell 远程处理配置了例外?还是完全禁用 Windows 防火墙?
  • 我已经尝试停用我的防火墙,并且已经将其他计算机添加到我的受信任主机列表中。
  • 两个主机是否在同一个工作组和同一个家庭组?尝试通过telnet:telnet <ip-address> 443连接到另一台主机。
  • 另一台电脑的443端口被关闭。但是,Winrm 使用 5985 和 5986 作为 HTTP 和 HTTPS 端口。
  • 嗯,你能连接到那些端口吗?

标签: powershell iis winrm


【解决方案1】:

帮助中提供了开始使用远程处理所需的所有内容:

 PS> Get-Help about_Remote_TroubleShooting -ShowWindow

如果您不在域中,请查看此部分:

HOW TO CONNECT REMOTELY FROM A WORKGROUP-BASED COMPUTER
-------------------------------------------------------
[..]

When the local computer is not in a domain, the following procedure is required
for remoting.

1. Configure the computer for HTTPS transport or add the names of the
   remote computers to the TrustedHosts list on the local computer.
[..]

【讨论】:

  • 我已经尝试停用我的防火墙,并且已经将其他计算机添加到我的受信任主机列表中。
猜你喜欢
  • 2014-08-25
  • 1970-01-01
  • 2019-05-12
  • 1970-01-01
  • 1970-01-01
  • 2017-04-16
  • 1970-01-01
  • 2019-08-05
  • 1970-01-01
相关资源
最近更新 更多