M365 – Powershell Script – Install-Module : The term ‘Install-Module’ is not recognized as the name of a 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.

Hi All,

Greetings for the day 🙂 LIFE IS BEAUTIFUL WITH M365 🙂

Today new issue and solution 🙂

I shared PowerShell script to execute with one of my colleague. So he started SharePoint Online Management Shell and try to execute the script.

While executing the script he got following error

Install-Module : The term ‘Install-Module’ is not recognized as the name of a 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.

M365 - PowerShell script - Error -  The term 'Install-Module' is not recognized as the name of a cmdlet
Fig1: M365 – PowerShell script – Error – The term ‘Install-Module’ is not recognized as the name of a cmdlet

Solution: This means that we didn’t have installed “Windows Management Framework 5.1” on our system.

We can download ” Windows Management Framework 5.1 ” from https://www.microsoft.com/en-us/download/details.aspx?id=54616

M365 - PowerShell scripts - Installing Windows Management Framework 5.1
Fig2: M365 – PowerShell script – Installing Windows Management Framework 5.1

Once we click on “Download” button as shown in Fig2 we will get the download options as

M365 - PowerShell script -   Installing Windows Management Framework 5.1 - Option selected is also works for Windows 10 even though options are till win 8
Fig3: M365 – PowerShell script – Installing Windows Management Framework 5.1 – Option selected is also works for Windows 10 or Windows server 2012 or Windows server 2012 R2 even though options are till win 8

Once “Windows Management Framework 5.1” is installed successfully (it may ask for restart) this issue will went away. Then enjoy the PowerShell cmdlets 🙂

Thanks for reading 🙂 Enjoy the journey, Life is beautiful 🙂

References:

Prasham Sabadra

LIFE IS VERY BEAUTIFUL. ENJOY THE WHOLE JOURNEY :) Founder of Microsoft 365 Junction, Speaker, Author, Learner, Developer, Passionate Techie. Certified Professional Workshop Facilitator / Public Speaker. Believe in knowledge sharing. Around 20+ years of total IT experience and 17+ years of experience in SharePoint and Microsoft 365 services Please feel free me to contact for any SharePoint / Microsoft 365 queries. I am also very much interested in behavioral (life changing) sessions like motivational speeches, Success, Goal Setting, About Life, How to live Life etc. My book - Microsoft 365 Power Shell hand book for Administrators and Beginners and 100 Power Shell Interview Questions - https://www.amazon.in/Microsoft-Administrators-Beginners-Interview-Questions/dp/9394901639/ref=tmm_pap_swatch_0?_encoding=UTF8&qid=1679029081&sr=8-11

You may also like...

2 Responses

  1. Luis Martins says:

    This does not work for WIndows 10

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from Microsoft 365

Subscribe now to keep reading and get access to the full archive.

Continue reading