Wednesday 15 June 2016

Configuring new DSC Pull server - error Nº1 - Error executing Start-DSCConfiguration

Hi all!

I'm starting another series of posts about my experiences with PowerShell DSC!!

As it can not be otherwise, I'm going to start with an error...so here we go!


the error:

You just configured a your new DSC Pull server, using xWebService resource, and created your first MOF file that you are going to use to start DSC Pull server configuration, and run:

Start-DscConfiguration -Path c:\\PullServer -Wait -Verbose

After some information messages...
The expression after '&' in a pipeline element produced an object that was not valid. It must result in a command name, a script block, or a CommandInfo object.
    + CategoryInfo          : InvalidOperation: (:) [], CimException
    + FullyQualifiedErrorId : BadExpression
    + PSComputerName        :

the solution:

This error appears because of known issue #143, reported in GitHub.

Although the version is in dev(at the moment I write this post), you can go here, download the full zip and copy files:


xPSDesiredStateConfiguration-dev.zip\xPSDesiredStateConfiguration-dev\DSCResources\MSFT_xDSCWebService\...
             MSFT_xDSCWebService.psm1
             PSWSIISEndpoint.psm1 

Then you only need to overwrite the old ones (remember to backup) at:
C:\Program Files\WindowsPowerShell\Modules\xPSDesiredStateConfiguration\3.10.0.0\DSCResources\MSFT_xDSCWebService
That's all!