Site icon WinCert

Install-Package: No match was found for the specified search criteria and module name ‘AZ’

<p>I recently attended an online Azure Administration course and had to install AZ tools from the PS repository using Powershell 7&period;x&period;<&sol;p>&NewLine;<p>I have used the following PS command&colon;<&sol;p>&NewLine;<p><strong>install-module -Name AZ -AllowClobber -Repository PSgallery<&sol;strong><&sol;p>&NewLine;<p>Even though I have followed course instructions I was unable to do so as I received the following error message&colon;<&sol;p>&NewLine;<p><strong>WARNING&colon; Unable to resolve package source &&num;8216&semi;https&colon;&sol;&sol;www&period;powershellgallery&period;com&sol;api&sol;v2&&num;8217&semi;<br &sol;>&NewLine;<&sol;strong><strong>Install-Package&colon; No match was found for the specified search criteria and module name &&num;8216&semi;AZ&&num;8217&semi;&period; Try Get-PSRepository to search for all available registered module repositories&period;<&sol;strong><&sol;p>&NewLine;<p><img class&equals;"alignnone size-full wp-image-4700" src&equals;"https&colon;&sol;&sol;www&period;wincert&period;net&sol;wp-content&sol;uploads&sol;2022&sol;07&sol;az-install-error4&period;jpg" alt&equals;"" width&equals;"934" height&equals;"83" &sol;><&sol;p>&NewLine;<p>In order to solve this issue&comma; I had to use the <strong>-scope<&sol;strong> attribute&period;<&sol;p>&NewLine;<p><strong>Install-Module -Name AZ -AllowClobber -Scope CurrentUser<&sol;strong><&sol;p>&NewLine;<p><img class&equals;"alignnone wp-image-4702 size-full" title&equals;"Install-Package&colon; No match was found for the specified search criteria and module name 'AZ'" src&equals;"https&colon;&sol;&sol;www&period;wincert&period;net&sol;wp-content&sol;uploads&sol;2022&sol;07&sol;az-install-error&period;jpg" alt&equals;"" width&equals;"925" height&equals;"116" &sol;><&sol;p>&NewLine;<p>As you can see from the image above I was able to install the &&num;8216&semi;AZ&&num;8217&semi; repository with that command&period;<&sol;p>&NewLine;<p><img class&equals;"alignnone wp-image-4704 size-full" title&equals;"Install-Package&colon; No match was found for the specified search criteria and module name 'AZ'" src&equals;"https&colon;&sol;&sol;www&period;wincert&period;net&sol;wp-content&sol;uploads&sol;2022&sol;07&sol;az-install-error-2&period;jpg" alt&equals;"" width&equals;"952" height&equals;"130" &sol;><&sol;p>&NewLine;<p>Hope this helps you with <strong>Install-Package&colon; No match was found for the specified search criteria and module name &&num;8216&semi;AZ&&num;8217&semi;<&sol;strong> error&period;<&sol;p>&NewLine;<p>Comments are welcome&excl;<&sol;p>&NewLine;

Exit mobile version