I have created a configuration to install SQL and SharePoint.
I have configured a LCM on my dev Node machine to pull the configuration from a Pull server. It did so flawlessly.
However after testing an updated configuration (Adding sharepoint service pack 1 as a package DSCresource). I now get multiple import-dscresource errors on the node. Here i listed the first one:
Any ideas to what can be causing this?
I tried removing all modules on the node, so that it pulls new modules from the pull server, but I am getting the samme import errors.
I attempted to remove downloaded modules on the pull server (both dsc module folder and normal module folder) and on the node. Then download and install them again on the Pull Server using the find-dscresource xxxx | install-module… cmlet and packing them correctly in the DscService\Modules folder.
The node pulling the configuration got the same errors… So it does not seem to be an issue with the modules themselves…
And only 3 of 8 modules give me the error similar to:
Could not import the PowerShell DSC resource: C:\Program Files\WindowsPowerShell\Modules\xWindowsUpdate\2.5.0.0\DscResources\MSFT_xWindowsUpdate
+ CategoryInfo : ResourceUnavailable: (:) [], CimException
+ FullyQualifiedErrorId : PsproviderImportFailure
+ PSComputerName : localhost
To be clear, this isn’t a “not found” error, it’s an “import error.” It’s finding the file = it just can’t import it for some reason. The only way to troubleshoot that is to open a console on the node and manually try to import the resource, using -verbose, to see if you can get any errors. Either that, or enable debugging on the node, run it all again, and check the Diagnostics log to see if you get anything more specific. There’s something IN the module that the node isn’t liking. For example, have you checked the ExecutionPolicy?