PowerShell

Install-Module: The term Install-Module is not recognized as the name of cmdlet, function, script file or operable program

Recently I was asked to implement PSWinReporting onto yet another domain. Happily I've started to install my 6 modules to get it up and running… but got stopped with an error message:

Install-Module: The term Install-Module is not recognized as the name of cmdlet, function, script file or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

Short description of problem
Install-Module PSTeams
Install-Module PSEventViewer
Install-Module PSWinReporting
Install-Module PSWriteColor
Install-Module ImportExcel
Install-Module PSSlack
Install-Module Errors

Turns out I was on version 4.0 of PowerShell which doesn't seem to support Install-Module. Luckily… I knew what to do…

How do I get rid of it?

Easiest way to solve it is by installing Windows Management Framework 5.1  which brings proper commands into the system. Simply click the link, install, reboot and enjoy your Install-Module commands.

Windows Management Framework 5.1

After reboot Install-Module no longer reports errors.

PS C:\Windows\system32> Install-Module PSTeams
PS C:\Windows\system32> Install-Module PSEventViewer
PS C:\Windows\system32> Install-Module PSWinReporting
PS C:\Windows\system32> Install-Module PSWriteColor
PS C:\Windows\system32> Install-Module ImportExcel
PS C:\Windows\system32> Install-Module PSSlack

Of course you can install all modules manually but that's just gonna get ugly later on when you want to have them up to date.

This post was last modified on July 25, 2018 10:17

Przemyslaw Klys

System Architect with over 14 years of experience in the IT field. Skilled, among others, in Active Directory, Microsoft Exchange and Office 365. Profoundly interested in PowerShell. Software geek.

Share
Published by
Przemyslaw Klys

Recent Posts

Upgrade Azure Active Directory Connect fails with unexpected error

Today, I made the decision to upgrade my test environment and update the version of…

2 months ago

Mastering Active Directory Hygiene: Automating Stale Computer Cleanup with CleanupMonster

Have you ever looked at your Active Directory and wondered, "Why do I still have…

3 months ago

Active Directory Replication Summary to your Email or Microsoft Teams

Active Directory replication is a critical process that ensures the consistent and up-to-date state of…

7 months ago

Syncing Global Address List (GAL) to personal contacts and between Office 365 tenants with PowerShell

Hey there! Today, I wanted to introduce you to one of the small but excellent…

12 months ago

Active Directory Health Check using Microsoft Entra Connect Health Service

Active Directory (AD) is crucial in managing identities and resources within an organization. Ensuring its…

1 year ago

Seamless HTML Report Creation: Harness the Power of Markdown with PSWriteHTML PowerShell Module

In today's digital age, the ability to create compelling and informative HTML reports and documents…

1 year ago