Unable to import modules in Powershell

I cannot import any modules into Powershell due to this error:

PS C:\Users\Administrator> import-module failoverclusters The term 'import-module' is not recognized as a cmdlet, function, operable program, or script file. Verify the term and try again. At line:1 char:14 + import-module <<<< failoverclusters 

This was a new installation of Windows Server 2008 Enterprise. I installed Powershell as a Windows function through Server Manager. It was not installed when installing Windows Server.

+4
source share
2 answers

This is because Windows 2008 only comes with PowerShell 1.0, which used Snapins. If you need module support: install PowerShell 2.0 or 3.0. Links for installers:

Powershell 2.0: x64 (64-bit) or x86 (32-bit)

PowerShell 3.0

To install PS 3.0, you need at least 2008 SP2 (and download Windows 6.0 64 or 32-bit).

+8
source

Try right-clicking the PowerShell icon and selecting the โ€œImport System Modulesโ€ option. Then run the Set-ExecutionPolicy RemoteSigned .

0
source

All Articles