DSC Pull Server Getting InternalServerError

I’m really lost with this one.

I have a new PullServer that I’ve setup, and set the pull mode on the client. All the code is attached. Every time an update occurs I get an InternalServerError.

PS C:\dsc> Invoke-CimMethod -ComputerName ClientName -Namespace root/microsoft/windows/desiredstateconfiguration `
>> -Class MSFT_DscLocalConfigurationManager -MethodName PerformRequiredConfigurationChecks `
>> -Arguments @{Flags = [uint32]1} -Verbose
>>
VERBOSE: Performing the operation “Invoke-CimMethod: PerformRequiredConfigurationChecks” on target “MSFT_DscLocalConfigurationManager”.
VERBOSE: Perform operation ‘Invoke CimMethod’ with following parameters, ‘‘methodName’ = PerformRequiredConfigurationChecks,‘className’ =
MSFT_DscLocalConfigurationManager,‘namespaceName’ = root/microsoft/windows/desiredstateconfiguration’.
VERBOSE: An LCM method call arrived from computer ClientName with user sid S-1-5-21-2127521184-1604012920-1887927527-6010656.
Invoke-CimMethod : The attempt to get the action from server
http://10.123.161.202/PSDSCPullServer/PSDSCPullServer.svc/Action(ConfigurationId=‘457ecc54-24ed-4b81-bcc3-21f0f6ec55b5’)/GetAction returned unexpected
response code InternalServerError.
At line:1 char:1

  • Invoke-CimMethod -ComputerName ClientName -Namespace root/microsoft/windows/des …
  •   + CategoryInfo          : InvalidResult: (root/microsoft/...gurationManager:String) [Invoke-CimMethod], CimException
      + FullyQualifiedErrorId : WebDownloadManagerGetActionUnsuccessful,Microsoft.PowerShell.DesiredStateConfiguration.Commands.GetDscActionCommand,Microsoft.Ma
     nagement.Infrastructure.CimCmdlets.InvokeCimMethodCommand
      + PSComputerName        : T10LSPLAB02
    
    

VERBOSE: Operation ‘Invoke CimMethod’ complete.

Now per this thread (https://powershell.org/forums/topic/dsc-pull-server-failure/) I ran the Test-xDSCResource -Name xDSCWebService and it returns true.

My config on the Pull Server is:
PS C:\dsc> Get-DscLocalConfigurationManager

AllowModuleOverwrite : False
CertificateID :
ConfigurationID :
ConfigurationMode : ApplyAndMonitor
ConfigurationModeFrequencyMins : 30
Credential :
DownloadManagerCustomData :
DownloadManagerName :
RebootNodeIfNeeded : False
RefreshFrequencyMins : 15
RefreshMode : PUSH
PSComputerName :

My Config on the ClientServer is:

AllowModuleOverwrite : True
CertificateID :
ConfigurationID : 457ecc54-24ed-4b81-bcc3-21f0f6ec55b5
ConfigurationMode : ApplyAndMonitor
ConfigurationModeFrequencyMins : 30
Credential :
DownloadManagerCustomData : {MSFT_KeyValuePair (key = “ServerUrl”), MSFT_KeyValuePair (key =
“AllowUnsecureConnection”)}
DownloadManagerName : WebDownloadManager
RebootNodeIfNeeded : False
RefreshFrequencyMins : 15
RefreshMode : Pull
PSComputerName :

This is a fresh Windows Server 2012 R2 VM and its never had DSC configured on it before. I honestly have no idea where to look from here. Thanks!

It’s the target node not communicating with the pull server, from what it looks like. Have you tried running a more detailed diagnostic on the node, using xPSCDiagnostics?

I am running the pull server on W12R2 VMs the target node is also a brand new W12R2 VM. I am seeing this exact behavior and am equally stumped. After running Get-xDscOperation and Get-xDscOperation I am seeing the target initiating pulls every 15 minutes with successful log entries for the communication and prep and then the following failure:

‘The attempt to get the action from server http://mssinf-tst001:8080/PSDSCPullServer/PSDSCPullServer.svc/Action(ConfigurationId=‘7fef55a0-d33c-443f-889e-6f7524accbcb’)/GetAction returned unexpected response code InternalServerError.’

The errorID in the eventlog is 0x1, so that is not much to search on.

Aside from how do I fix this, I have two questions:

  • I was unable to find xPSCDiagnostics mentioned above, are those different than the xDscDiagnostics I have installed and have been using?
  • I used ‘The DSC Book’ eBook from PS.org for the setup of the Pull server and the node. Are there additional resources I should be looking at to help me with the initial setup?

Thanks.

You’ve got the right module name; sorry - iPad answering can be difficult.

Do you have KB3222800 installed? It’s mentioned in The DSC Book, but want to double-check. Usually, “total weirdness” indicates it’s missing.

Thanks for the response.

I am still seeing the issue, the node is regularly attempting to pull and failing with the same error as above.

I have confirmed that both VMs have KB2883200 installed.

Chris Whinihan

So, from there, I’d run a diagnostics trace to cover the next pull attempt, and see what turns up in the log. And, although it may not produce anything at all, you can try hitting that URL from the error by using a web browser. Wouldn’t hurt to see if anything does show up.

Thanks. It looks like this was a combination of a couple of things getting changed during initial troubleshooting of the configuration. The Pull URL and a new GUID. I reset the URL and cleared out everything and ran it with a new GUID and now I can see it running without error. Thanks for your assistance.

Chris Whinihan