0
votes

I've been trying to setup a DSC Pull Server on a Windows Server 2012 R2 (both server and client), I've juste installed the CTP version of WMF 5. I've configured my client LCM to listen to the Server URL for a specific configuration, when trying to force the LCM to pick up the configuration from the server and apply it I get an error, below the details. How do I force the LCM:

    $params = @{
    Namespace = ‘root/Microsoft/Windows/DesiredStateConfiguration’
    ClassName = ‘MSFT_DSCLocalConfigurationManager’
    MethodName = ‘PerformRequiredConfigurationChecks’
    Arguments = @{
    Flags = [uint32]2
    }
    }

    Invoke-CimMethod @params

And this is the error I get:

Invoke-CimMethod : The requested object could not be found. At C:\PSDSC\DSCForceLCM.ps1:10 char:1
+ Invoke-CimMethod @params
+ ~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (root/Microsoft/...gurationManager:String) [Invoke-CimMethod], CimException
    + FullyQualifiedErrorId : MI RESULT 6,Microsoft.Management.Infrastructure.CimCmdlets.InvokeCimMethodCommand
1
Your code sample as posted here is using "smart quotes". If those are actually in the code, then that is probably causing the problem. Please confirm and update your code sample.briantist

1 Answers

0
votes

The latest WMF 5.0 Preview (Feb) has a cmdlet Update-DscConfiguration which will force DSC to do a pull (assuming that RefreshMode is set to Pull)