【问题标题】:The specified module ActiveDirectory was not loaded未加载指定的模块 ActiveDirectory
【发布时间】:2019-02-25 23:56:02
【问题描述】:

我有一个 SSIS 作业,它执行试图从 Active Directory 中提取信息的 powershell 模块。但是,当我运行脚本时,我得到了这个错误:

指定的模块 ActiveDirectory 没有被加载,因为没有有效的 在任何模块目录中都找到了模块文件

我发现了这个similar 问题,但是他们使用的是 Windows Server 2008,而我使用的是 Windows Server 2016。我尝试按照问题中的说明进行操作,但我找不到“远程服务器管理”工具”或“Windows Powershell 的 Active Directory 模块。”

【问题讨论】:

  • 您的服务器上是否启用了 RSAT 角色?
  • @TheIncorrigible1 我该如何检查?我不是真正的服务器管理员
  • Get-WindowsFeature -Name RSAT, RSAT-Role-Tools, RSAT-AD-Tools, RSAT-AD-PowerShell
  • 如果未启用,请使用Add-WindowsFeature 启用它们,您将拥有可用的ActiveDirectory 模块。

标签: powershell sql-server-2016 windows-server-2016


【解决方案1】:

你能检查Active Directory Web Services服务是否在services下运行吗?

如果没有启动它并运行下面的命令

Get-module -list

您可以检查是否列出了 Active Directory 模块。

运行以下命令以启用 Active Directory 模块

Add-WindowsFeature RSAT-AD-PowerShell

【讨论】:

  • ntweekly.com/2016/07/03/… 看到这个链接,可能对你有帮助。
  • 如何启动 Active Directory Web 服务?我不是真正的服务器管理员
  • @DForck42 打开 services.msc 并查找 Active Directory Web 服务
  • @DForck42 您是否运行了 PowerShell 命令 Add-WindowdFeature RSAT-AD-PowerShell?
  • 我查看了服务,但没有看到 Active Directory Web 服务
猜你喜欢
  • 1970-01-01
  • 2013-10-11
  • 1970-01-01
  • 2012-08-15
  • 2021-08-17
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2021-02-27
相关资源
最近更新 更多