Update-DscConfiguration with partial configs is behaving different

This topic contains 5 replies, has 4 voices, and was last updated by Profile photo of TyMac TyMac 4 months ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #39897
    Profile photo of TyMac
    TyMac
    Participant

    I just created a partial configuration on several different machines and the results after "Update-DscConfiguration -Verobse -Wait" are not the same as they were when the LCM was not configured as such. I'll commit a change for one of my config scripts and deploy the scripts to the pull server and run the aforementioned command on a node but the configuration changes will not automatically occur. It will occur several minutes later however... presumably on a normal LCM config check.

    Is this expected behavior for partial configs?

    You can see below that the check is running "successfully" – but the changes do not occur on the run as they did before:

    PS C:\Users\Administrator> Update-DscConfiguration -Verbose -Wait
    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 WIN-F3BTDUDK8NO with user sid
    S-1-5-23-1974293225-1548797301-293546912-500.
    VERBOSE: [WIN-F4BTDUDK7NO]:                            [] Executing Get-Action with configuration 's checksum returned
    result status: GetConfiguration.
    VERBOSE: [WIN-F3BTDUDK8NO]:                            [] Checksum is different. LCM will execute GetConfiguration to
    pull configuration .
    VERBOSE: [WIN-F3BTDUDK8NO]:                            [] Executing GetConfiguration succeeded. Configuration
    DSCConfigDesktopApps was pulled from server.
    VERBOSE: [WIN-F3BTDUDK8NO]:                            [] Executing GetConfiguration succeeded. Configuration
    DSCConfigSystemBase was pulled from server.
    VERBOSE: Operation 'Invoke CimMethod' complete.
    VERBOSE: Time taken for configuration job to complete is 5.001 seconds
    
    #40020

    Can you please share the metaconfig on this target node?

    #40056
    Profile photo of Arie H
    Arie H
    Participant

    Did you happen to leave the ConfigurationID=" in the LCM script by any chance ?

    LCM setting script will help indeed.

    #40075
    Profile photo of TyMac
    TyMac
    Participant

    @Indhu:

    What do you mean exactly by "metaconfig"? You want the .mof?

    @Arie:

    ConfigurationID=" is not in the LCM config:

    [DSCLocalConfigurationManager()]
    Configuration SampleRegistrationMetaConfig
    {
    
        Settings
            {
                RefreshFrequencyMins = 30;
                RefreshMode = "PULL";
                ConfigurationMode = "ApplyAndAutoCorrect";
                AllowModuleOverwrite = $true;
                RebootNodeIfNeeded = $true;
                ConfigurationModeFrequencyMins = 60;
    
            }
    
            ConfigurationRepositoryWeb ConfigurationManager
            {
                ServerURL = "https://xxxxxx:8080/PSDSCPullServer.svc"
                RegistrationKey = "xxxx-xxxx-xxxxx-xxxx-xxxx"
                ConfigurationNames = @('DSCConfigDesktopApps', 'DSCConfigSystemBase')
                AllowUnsecureConnection = $false
            }
            
            PartialConfiguration DSCConfigDesktopApps
            {
                Description = 'Add desktop applicaitons'
                RefreshMode = 'Pull'
                ConfigurationSource = '[ConfigurationRepositoryWeb]ConfigurationManager'
            }
             
            PartialConfiguration DSCConfigSystemBase
            {
                Description = 'Config baseline system'
                RefreshMode = 'Pull'
                ConfigurationSource = '[ConfigurationRepositoryWeb]ConfigurationManager'
            }
    }
    
    SampleRegistrationMetaConfig -outputpath C:\dsc
    Set-DscLocalConfigurationManager -Path C:\dsc -Verbose
    
    #40178
    Profile photo of Nitin Gupta
    Nitin Gupta
    Participant

    This is a known issue in WMF 5. 0 RTM which is already fixed in windows internal builds. Workaround is to use

    Start-DscConfiguration -wait -verbose -useExisting
    

    after performing Update-DscConfiguration.

    #40511
    Profile photo of TyMac
    TyMac
    Participant

    That worked! Thanks!!!

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.