-
Notifications
You must be signed in to change notification settings - Fork 29
Open
Description
Details of the scenario you tried and the problem that is occurring
Verbose output of Get-TargetResource
returns Microsoft.UpdateServices.Internal.BaseApi.UpdateServer
instead of WSUS server name
Verbose logs showing the problem
VERBOSE: [SRV1]: LCM: [ Start Resource ] [[UpdateServicesApprovalRule]Approval]
VERBOSE: [SRV1]: LCM: [ Start Test ] [[UpdateServicesApprovalRule]Approval]
VERBOSE: [SRV1]: [[UpdateServicesApprovalRule]Approval] Identified WSUS server information: Microsoft.UpdateServices.Internal.BaseApi.UpdateServer
VERBOSE: [SRV1]: LCM: [ End Test ] [[UpdateServicesApprovalRule]Approval] in 0.0470 seconds.
VERBOSE: [SRV1]: LCM: [ Skip Set ] [[UpdateServicesApprovalRule]Approval]
VERBOSE: [SRV1]: LCM: [ End Resource ] [[UpdateServicesApprovalRule]Approval]
Suggested solution to the issue
Line 55 in dd6be4e
Write-Verbose -Message ('Identified WSUS server information: {0}' -f $WsusServer) |
Change the line to:
Write-Verbose -Message ('Identified WSUS server information: {0}' -f $WsusServer.Name)
The DSC configuration that is used to reproduce the issue (as detailed as possible)
Configuration WSUSProduct {
Import-DscResource -ModuleName 'PSDesiredStateConfiguration'
Import-DscResource -ModuleName 'UpdateServicesDsc' -ModuleVersion 1.2.1
Node localhost {
UpdateServicesApprovalRule Approval {
Ensure = 'Present'
Name = 'Test Approval Rule'
Classifications = @(
# Updates
'cd5ffd1e-e932-4e3a-bf74-18bf0b1bbd83'
)
Products = 'Windows Server 2016'
ComputerGroups = 'All Computers'
Enabled = $true
}
}
}
The operating system the target node is running
OsName : Microsoft Windows Server 2019 Datacenter
OsOperatingSystemSKU : DatacenterServerEdition
OsArchitecture : 64-bit
WindowsVersion : 1809
WindowsBuildLabEx : 17763.1.amd64fre.rs5_release.180914-1434
OsLanguage : en-US
OsMuiLanguages : {en-US}
Version and build of PowerShell the target node is running
Name Value
---- -----
PSVersion 5.1.17763.1490
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.17763.1490
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
Version of the DSC module that was used
Name Version Path
---- ------- ----
UpdateServicesDsc 1.2.1 C:\Program Files\WindowsPowerShell\Modules\UpdateServicesDsc\1.2.1\UpdateServicesDsc.psd1
Metadata
Metadata
Assignees
Labels
No labels