Closed mjcarrabine closed 4 years ago
Hi @mjcarrabine, what happens if you just run Test-DscConfiguration -Detailed? (So without -Verbose?) Is that returning True?
FYI, I am using Azure Automation as the pull server if that makes a difference here.
Running Update-DscConfiguration
returns Compliant in Azure once.
Then running Test-DscConfiguration
returns InDesiredState = False
PS C:\windows\system32> Update-DscConfiguration
Id Name PSJobTypeName State HasMoreData Location Command
-- ---- ------------- ----- ----------- -------- -------
9 Job9 Configuratio... Running True localhost Update-DscConfiguration
PS C:\windows\system32> Test-DscConfiguration -Detailed
PSComputerName ResourcesInDesiredState ResourcesNotInDesiredState InDesiredState
-------------- ----------------------- -------------------------- --------------
localhost {[Group]AddToAdministrators... {[xRDRemoteApp]Win32Calc, [... False
PS C:\windows\system32> Test-DscConfiguration -Detailed | fl
InDesiredState : False
ResourcesInDesiredState : {[Group]AddToAdministrators, [File]ODBC, [Package]InstallODBC,
[WindowsFeature]RDS_RD_Server...}
ResourcesNotInDesiredState : {[xRDRemoteApp]Win32Calc, [xRDRemoteApp]iexplore}
ReturnValue : 0
PSComputerName : localhost
PS C:\windows\system32> (Test-DscConfiguration -Detailed).ResourcesNotInDesiredState | fl
ConfigurationName : IRM_01_Config
DependsOn : {[xRDSessionCollection]RDSessionCollection}
ModuleName : xRemoteDesktopSessionHost
ModuleVersion : 1.9.0.0
PsDscRunAsCredential :
ResourceId : [xRDRemoteApp]Win32Calc
SourceInfo : ::1832::3::xRDRemoteApp
DurationInSeconds : 3.945
Error :
FinalState :
InDesiredState : False
InitialState :
InstanceName : Win32Calc
RebootRequested : False
ResourceName : xRDRemoteApp
StartDate : 12/17/2019 9:38:25 AM
StateChanged : False
PSComputerName : localhost
ConfigurationName : IRM_01_Config
DependsOn : {[xRDSessionCollection]RDSessionCollection}
ModuleName : xRemoteDesktopSessionHost
ModuleVersion : 1.9.0.0
PsDscRunAsCredential :
ResourceId : [xRDRemoteApp]iexplore
SourceInfo : ::1839::3::xRDRemoteApp
DurationInSeconds : 3.88
Error :
FinalState :
InDesiredState : False
InitialState :
InstanceName : iexplore
RebootRequested : False
ResourceName : xRDRemoteApp
StartDate : 12/17/2019 9:38:29 AM
StateChanged : False
PSComputerName : localhost
Hi @mjcarrabine, I was able to reproduce this issue and have created a PR to fix this issue.
Details of the scenario you tried and the problem that is occurring
I am using the XRemoteDesktopSessionHost resource to deploy my Remote Desktop Session Host instance, and everything seems to be working correctly.
However, the xRDRemoteApp resources are running successfully, but then Test-DscConfiguration is showing them as InDesiredState: False due to what looks like an issue with the Verbose property.
Any thoughts?
I can reproduce this on 2 machines now.
Verbose logs showing the problem
Start-DscConfiguration -Wait -Verbose -UseExisting
returnsRunning
Start-DscConfiguration -Wait -Verbose -UseExisting
a second time returnsSuggested solution to the issue
I don't have one at this time.
The DSC configuration that is used to reproduce the issue (as detailed as possible)
The operating system the target node is running
Version and build of PowerShell the target node is running
Version of the DSC module that was used ('dev' if using current dev branch)
1.9.0.0