Run ACTIVE Directory commands from PowerShell installed on Linux RHEL 7

Occasional Visitor



I am trying to run the Active Directory commands from PowerShell installed on Linux RHEL 7.


has anyone able to do this from Linux.


PS /root> import-module ActiveDirectory
Import-Module: The specified module 'ActiveDirectory' was not loaded because no valid module file was found in any module directory.



PS /root> get-module -listavailable

Directory: /opt/microsoft/powershell/7/Modules

ModuleType Version PreRelease Name PSEdition ExportedCommands
---------- ------- ---------- ---- --------- ----------------
Manifest 1.2.5 Microsoft.PowerShell.Archive Desk {Compress-Archive, Expand-Archive}
Manifest Microsoft.PowerShell.Host Core {Start-Transcript, Stop-Transcript}
Manifest Microsoft.PowerShell.Management Core {Add-Content, Clear-Content, Clear-ItemProperty, Join-Path…}
Manifest Microsoft.PowerShell.Security Core {Get-Credential, Get-ExecutionPolicy, Set-ExecutionPolicy, ConvertFrom-SecureString…}
Manifest Microsoft.PowerShell.Utility Core {Export-Alias, Get-Alias, Import-Alias, New-Alias…}
Script 1.4.7 PackageManagement Desk {Find-Package, Get-Package, Get-PackageProvider, Get-PackageSource…}
Script 2.2.5 PowerShellGet Desk {Find-Command, Find-DSCResource, Find-Module, Find-RoleCapability…}
Script 2.0.5 PSDesiredStateConfiguration Core {Configuration, New-DscChecksum, Get-DscResource, Invoke-DscResource}
Script 2.1.0 PSReadLine Desk {Get-PSReadLineKeyHandler, Set-PSReadLineKeyHandler, Remove-PSReadLineKeyHandler, Get-PSR…
Binary 2.0.3 ThreadJob Desk Start-ThreadJob


1 Reply

Hello @Jayeshpc,

Can you please elaborate? What are you trying to achieve?

Can you please describe your use case?


As described here ActiveDirectory module is only supported in Windows and in PowerShell core relies on WindowsCompatibility module functionality:



Hope that helps.