I have a problem, on one of my servers cannot complete “Start-DscConfiguration”. It always stucks in the same moment (line VERBOSE: Exporting alias ‘nwsn’). I do not see anything interesting in logs (application and dsc). Does anybody knows what is wrong? (I reinstalled WMF 5.1 several times but it does not help).
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Get-DSCConfiguration.cdxml’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Get-DSCLocalConfigurationManager.cdxml’
.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Restore-DSCConfiguration.cdxml’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Get-DscConfigurationStatus.cdxml’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Stop-DscConfiguration.cdxml’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Remove-DscConfigurationDocument.cdxml’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Disable-DscDebug.cdxml’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\Enable-DscDebug.cdxml’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\DSCClassResources\WindowsPackageCab\Win
dowsPackageCab.psd1’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\DSCClassResources\WindowsPackageCab\Win
dowsPackageCab.psm1’.
VERBOSE: Loading module from path
‘C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\DSCResources\CompositeResourceHelper.ps
m1’.
VERBOSE: Exporting function ‘BuildResourceCommonParameters’.
VERBOSE: Exporting function ‘BuildResourceString’.
VERBOSE: Importing function ‘BuildResourceCommonParameters’.
VERBOSE: Importing function ‘BuildResourceString’.
VERBOSE: Importing function ‘BuildResourceCommonParameters’.
VERBOSE: Importing function ‘BuildResourceString’.
VERBOSE: Importing function ‘BuildResourceCommonParameters’.
VERBOSE: Importing function ‘BuildResourceString’.
VERBOSE: Importing function ‘BuildResourceCommonParameters’.
VERBOSE: Importing function ‘BuildResourceString’.
VERBOSE: Importing function ‘BuildResourceCommonParameters’.
VERBOSE: Importing function ‘BuildResourceString’.
VERBOSE: Time taken for configuration job to complete is 0.082 seconds
VERBOSE: Exporting function ‘New-PSWorkflowSession’.
VERBOSE: Exporting alias ‘nwsn’.
Does this occur with a “full” configuration MOF, or have you also experienced this with a “minimal” configuration that just attempts to… I dunno, set an environment variable? I wasn’t expecting to see Workflow crop up, is why I ask.
unfortunately there is no events that might help. the only error I see is because current configuration was stopped by “-Force” parameter…
I can also add that the command and whole script is ok because it has successfully run on many other servers. I was doing it many times on the server that has the problem, during one of tries it just stopped working correctly and I don’t know why.
I checked the most current json file in ‘C:\Windows\System32\Configuration\ConfigurationStatus’ - this is location where DSC logs are also being stored. In the log file I found such line:
[DSCEngine] Warning LCM is in Debug ‘ResourceScriptBreakAll’ mode. Resource script processing will be stopped to wait for PowerShell script debugger to attach."},
The ‘ResourceScriptBreakAll mode’ has been set when I enabled debugging by ‘Enable-DscDebug -BreakAll’ cmdlet.
After I disabled debugging by the ‘Disable-DscDebug’ cmdlet, my script completed as expected.