Powershell 无法打开 - 错误 "Path cannot be the empty string or all whitespace"

标签 powershell windows-server-2012

我只是想在我的服务器上打开 Powershell。它打开大约 5 秒,然后关闭,在关闭之前没有显示任何错误或任何内容。我在 Windows Powershell 事件日志中唯一能看到的是它给出了以下错误:

"Settings: Path cannot be the empty string or all whitespace."

我正在运行 WMF 4、Server 2012 R2、Exchange Server 2016(我认为这与此无关)。当我用谷歌搜索“Powershell Path不能是空字符串或全空白”时我看到的任何其他帖子似乎总是与某人编程有关。我只是想打开 powershell。

最佳答案

原来这是一个组策略设置,特别是“计算机配置\策略\Windows 组件\Windows Powershell\打开 Powershell 转录”。它已在我们的域中打开,因为 Powershell V5 正在/已经推送给每个人(除了我们的 Exchange 服务器)。一旦我更改了靠近我的 Exchange 服务器的 GPO 上的设置,执行了 gpupdate,然后重新启动服务器,它就再次开始正常工作。

此外,无论谁对我的问题投了反对票,您能解释一下为什么它被反对吗?或者你只是想成为反对者的插入者?

关于Powershell 无法打开 - 错误 "Path cannot be the empty string or all whitespace",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45142493/

相关文章:

powershell - 如何通过 PowerShell 或模板将 Azure 混合连接链接到 Azure Web 应用?

Powershell递归搜索选择.txt文件,然后将所有文件的内容输出到单个.txt文件中

python - 在没有互联网访问且没有内部 pypi 服务器的生产系统(Windows)上安装 python 包

variables - 取得一个结果集(例如listofcomputers.txt),并对结果集的每个项目运行一个copy-item命令

powershell - 将文件夹中的每个 .flac 文件转换为 320kbps .mp3,而不丢失元数据

windows - 如何在 PowerShell 上安装 git(在 PowerShell 上使用 bash)?

windows - Appcmd.exe isapiCgiRestriction 错误找不到请求的集合元素

php - "Object named IIS_IUSRS could not be found"将用户添加到 PHP session 目录 iis 8

python - AWS 上的 Windows Server 2012 上的虚拟监视器或显示器

linux - Odoo 11 我应该选择哪个环境