Powershell. Troubleshooting modules
I am using Import-module to import a module that exists on the machine. It successfully imports the module but none of the cmdlets are available. I have verified that the module exists in my ps path. I have another functioning machine that has the exact same windows 7 version, same powershell 3.0 version and same .net version. On the broken machine if I run import-module and then run get-module it does show that module listed but none of the cmdlets are listed in the ExportedCommands field. On my working machine all of the cmdlets are displayed and function when I use them. I have tried remove-module and then import-module. I have tried moving the module from a working machine to the non working machine and tried importing again. Execution policy is set the same on both machines. Is there a good way to go about troubleshooting missing cmdlets? 
January 30th, 2015 3:33am

Are you missing a file in the modules folder?  That is usually the cause.

Compare the folder contents on the two machines with Compare-Object.

Free Windows Admin Tool Kit Click here and download it now
January 30th, 2015 4:26am

Thanks jrv. I will check into this but I thought I had this covered by copying the folder from a working machine to this broken machine would have covered this. I am still a bit lost.

Inside the psd file is a line that says NestedModules="Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets"

Is there a way for me to look into this?

January 30th, 2015 6:53am

Script modes can becopied but binaries have to be installed.  THat is a DLL that need to be installed and registered.

"Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets" is a binary stored in the GAC. 

DLLSuite has to be installed and licensed.

 

Free Windows Admin Tool Kit Click here and download it now
January 30th, 2015 7:25am

That makes sense and in some modules I see the dll listed. I don't see that in this module. I do so this though, NestedModules="Microsoft.Security.ApplicationId.PolicyManagement.Cmdlets"

Is there a way for me to dig into this line any further?

January 30th, 2015 7:31am

No.  Registered software has to be installed.  Contact the vendor for further information.
Free Windows Admin Tool Kit Click here and download it now
January 30th, 2015 7:33am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics