Powershell Binary Module not found but installed

Question:

I’ve created a Binary Powershell Module called ODBCManager. After installing from a feed, I am able to use it’s functions successfully, but Get-Module does not find it by name (Get-Module -Name ODBCManager returns null). Get-Module -ListAvailable will show it after a 2 minute query, so it’s definitely installed. Also -Verbose on installation says success.

  • I have it hosted in ProGet under a Powershell Modules Feed
  • On Publish, folder name and DLL name are the same
  • Manifest has been created
  • Functions export and execute as expected

Manifest:

Have I forgot something? Because I’ve tried everything.


EDIT: After help from @BenH I was able to research further and found you can call Get-Module -ListAvailable -Name ODBCManager to quickly show your module installed, but not imported. — For future reference!

Answer:

Install-Module and Import-Module are different. Get-Module returns all of the Modules that are imported and Get-Module -ListAvailable returns all of the modules that are installed.

Thus your module is “Installed” but not “Imported”.

With later versions of PowerShell, modules are dynamically imported if their functions/cmdlets are defined in the exported functions/cmdlets of the .psd1. But until they are imported, Get-Module will not list them.

Try this:

Source:

Powershell Binary Module not found but installed by licensed under CC BY-SA | With most appropriate answer!

Leave a Reply