AzureResourceManager.psd1 file is missing

Issue: the following command fails: Import-Module “C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\ResourceManager\AzureResourceManager\AzureResourceManager.psd1”

with error: “C:\Program Files (x86)\Microsoft SDKs\Azure\PowerShell\ResourceManager\AzureResourceManager\AzureResourceManager.psd1 file is missing”

Solution: You may not have Azure PowerShell installed, check add/remove programs etc to see.  If you do not have Azure PowerShell installed, then install it.

If you do have Azure PowerShell installed and you have Azure PowerShell 1.0.1 or newer you are getting the error because AzureResourceManager.psd1 is depricated. In this case, see below for solution:

There is no AzureResourceManager.psd1 in 1.0.1, AzureRM loads it’s modules differently than previous versions.  AzureResourceManager was deprecated after The easiest way to get this working may be by cleaning up and removing old versions:
1) Check “C:\Program Files\WindowsPowerShell\Modules”
2) delete the AzureResourceManager folder

If you have WMF 5 (or win 10) installed do the following:

Install-Module -Name AzureRM

Import-Module -Name AzureRM

Install-AzureRM or Update-AzureRM

You will now see a lot of new folders in C:\Program Files\WindowsPowerShell\Modules called AzureRM.xxxx In : C:\Program Files\WindowsPowerShell\Modules\AzureRM<version>\AzureRM.psm1

Now there is a function called Import-AzureRM that imports all the new modules.  Yay!


Leave a Reply

Your email address will not be published. Required fields are marked *

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