Cannot getting started

Running DSC labs, and yesterday I set up DSC Pull server nr 3 (DSC03) according to my documentation. Windows 2012 R2, Full Windows Update and:
Add-WindowsFeature Dsc-Service
winrm quickconfig
& ‘C:\Filer\Windows Management Framework 5.0 ProdPreview\Win8.1AndW2K12R2-KB3066437-x64.msu’
Find-DscResource -moduleName xPSDesiredStateConfiguration
Install-Module xPSDesiredStateConfiguration -Verbose

Everything as expected.

Then I was support to configure DSC Pull service, and…

PSDesiredStateConfiguration\Node : The variable ‘$notAllowedValue’ cannot be retrieved because it has not been set.
At C:\Filer.old\DSC02\DSC\Configurations\DSC char:5

  • Node $ComputerName
  • ~~~~
    • CategoryInfo : InvalidOperation: (notAllowedValue:String) [PSDesiredStateConfiguration\node], ParentContainsErrorRecordException
    • FullyQualifiedErrorId : VariableIsUndefined,PSDesiredStateConfiguration\node

PSDesiredStateConfiguration\Node : An exception was raised while processing Node ‘dsc03’: Index operation failed; the array index evaluated to null.
At C:\Filer.old\DSC02\DSC\Configurations\DSC char:5

  • Node
    At C:\Filer.old\DSC02\DSC\Configurations\DSC char:5
  • Node $ComputerName
  • ~~~~
    • CategoryInfo : InvalidOperation: (:slight_smile: [Write-Error], InvalidOperationException
    • FullyQualifiedErrorId : FailToProcessNode,PSDesiredStateConfiguration\node
      Update-DependsOn : Index operation failed; the array index evaluated to null.
      At C:\windows\system32\windowspowershell\v1.0\Modules\PSDesiredStateConfiguration\PSDesiredStateConfiguration.psm1:2181 char:17
  • … Update-DependsOn $Script:NodesInThisConfiguration[$mofNod …
  •             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    • CategoryInfo : InvalidOperation: (:slight_smile: [Update-DependsOn], RuntimeException
    • FullyQualifiedErrorId : NullArrayIndex,Update-DependsOn

Googling some of the keywords gives me nothing, like $notAllowedValue.
The configuration is pretty simple, it is standard “copy-paste code” from the net.

configuration NewPullServer
param ( [string[]]$ComputerName = ‘localhost’ )

Import-DSCResource -ModuleName xPSDesiredStateConfiguration
#Import-DscResource –ModuleName ‘PSDesiredStateConfiguration’

Node $ComputerName

    WindowsFeature DSCServiceFeature
        Ensure = “Present”
        Name   = “DSC-Service”
    xDscWebService PSDSCPullServer
        Ensure                  = “Present”
        EndpointName            = “PSDSCPullServer”
        Port                    = 8080
        PhysicalPath            = “$env:SystemDrive\inetpub\wwwroot\PSDSCPullServer”
        CertificateThumbPrint   = “AllowUnencryptedTraffic”
        ModulePath              = “$env:PROGRAMFILES\WindowsPowerShell\DscService\Modules”
        ConfigurationPath       = “$env:PROGRAMFILES\WindowsPowerShell\DscService\Configuration”
        State                   = “Started”
        DependsOn               = “[WindowsFeature]DSCServiceFeature”
    xDscWebService PSDSCComplianceServer
        Ensure                  = “Present”
        EndpointName            = “PSDSCComplianceServer”
        Port                    = 9080
        PhysicalPath            = “$env:SystemDrive\inetpub\wwwroot\PSDSCComplianceServer”
        CertificateThumbPrint   = “AllowUnencryptedTraffic”
        State                   = “Started”
        IsComplianceServer      = $true
        DependsOn               = (“[WindowsFeature]DSCServiceFeature”,”[xDSCWebService]PSDSCPullServer”)


#This line actually calls the function above to create the MOF file.
NewPullServer –ComputerName dsc03 -OutputPath ‘C:\DSC\DSC Server’

#Start-DscConfiguration -Path ‘C:\DSC\DSC Server’ –Wait -Verbose
#Start-Process -FilePath http://dsc03:8080/PSDSCPullServer.svc/

I am pretty lost here. I guess it is a really simple error, but I cannot find it.
Any ideas?

Forgot one important thing. …

I can run this config on DSC01 / DSC02, no errors.
In fact, true copy and paste, run. No errors.

I haven’t been able to find any reference to that variable in the PSDesiredStateConfiguration or xPSDesiredStateConfiguration modules; not sure where it’s coming from. In any case, the error looks like something that would come up with StrictMode has been turned on. Try running Set-StrictMode -Off , and then running the code again to see if it makes any difference.

No clue what happend here, but the error is resolved now.

  • Moved the server to a new OU.
    not really a big difference, but some GPO’s are different.
    Maybe StrictMode is effected (?) and I know Windows Update settings are different. (Option to bypass WSUS).
  • Rebooted.


Checked Windows Update logs, no new stuff there…
Honest: Strange… Wish I had the time to investigate this.


I have just made a test with Windows 2012 and WMF 5 production preview and I confirm the Dave’s solution, the problem is with Set-StrictMode. You have to turn off (Set-StrictMode -Off) before “Configuration” block.