Closed NikCharlebois closed 5 years ago
Hello Nick,
That might be related, i always getting exceptions with appdomain extraction, see the example below:
PS C:\Users\spfarm> SharePointDSC.Reverse.ps1 To execute the same extraction process unattended, run the following command: .\SharePointDSC.Reverse.ps1 -ComponentsToExtract @("SPWebApplicationAppDomain","SPWebApplication") Scanning Operating System Version... Scanning SQL Server Version... Scanning Patch Levels... Configuring Dependencies... [ SP ] Generating the SharePoint Prerequisites Installation... [ SP ] Generating the SharePoint Binary Installation... [ SP ] Scanning Web Application(s)... Scanning SPWebApplication [1/2] {mysite - 8888} VERBOSE: Executing as the local run as user SKY\spfarm VERBOSE: Leaving BeginProcessing Method of Get-SPWebApplication. VERBOSE: Leaving ProcessRecord Method of Get-SPWebApplication. VERBOSE: Leaving EndProcessing Method of Get-SPWebApplication. VERBOSE: Leaving BeginProcessing Method of Get-SPAuthenticationProvider. VERBOSE: Leaving ProcessRecord Method of Get-SPAuthenticationProvider. VERBOSE: Leaving EndProcessing Method of Get-SPAuthenticationProvider. -> Scanning SharePoint Designer Settings VERBOSE: Executing as the local run as user SKY\spfarm VERBOSE: Leaving BeginProcessing Method of Get-SPFarm. VERBOSE: Leaving ProcessRecord Method of Get-SPFarm. VERBOSE: Leaving EndProcessing Method of Get-SPFarm. VERBOSE: Leaving BeginProcessing Method of Get-SPWebApplication. VERBOSE: Leaving ProcessRecord Method of Get-SPWebApplication. VERBOSE: Leaving EndProcessing Method of Get-SPWebApplication. VERBOSE: Leaving BeginProcessing Method of Get-SPDesignerSettings. VERBOSE: Leaving ProcessRecord Method of Get-SPDesignerSettings. VERBOSE: Leaving EndProcessing Method of Get-SPDesignerSettings. VERBOSE: Executing as the local run as user SKY\spfarm VERBOSE: Leaving BeginProcessing Method of Get-SPWebApplication. VERBOSE: Leaving ProcessRecord Method of Get-SPWebApplication. VERBOSE: Leaving EndProcessing Method of Get-SPWebApplication. -> Scanning Outgoing Email Settings Scanning SPWebApplication [2/2] {SharePoint - 80} VERBOSE: Executing as the local run as user SKY\spfarm VERBOSE: Leaving BeginProcessing Method of Get-SPWebApplication. VERBOSE: Leaving ProcessRecord Method of Get-SPWebApplication. VERBOSE: Leaving EndProcessing Method of Get-SPWebApplication. VERBOSE: Leaving BeginProcessing Method of Get-SPAuthenticationProvider. VERBOSE: Leaving ProcessRecord Method of Get-SPAuthenticationProvider. VERBOSE: Leaving EndProcessing Method of Get-SPAuthenticationProvider. -> Scanning SharePoint Designer Settings VERBOSE: Executing as the local run as user SKY\spfarm VERBOSE: Leaving BeginProcessing Method of Get-SPFarm. VERBOSE: Leaving ProcessRecord Method of Get-SPFarm. VERBOSE: Leaving EndProcessing Method of Get-SPFarm. VERBOSE: Leaving BeginProcessing Method of Get-SPWebApplication. VERBOSE: Leaving ProcessRecord Method of Get-SPWebApplication. VERBOSE: Leaving EndProcessing Method of Get-SPWebApplication. VERBOSE: Leaving BeginProcessing Method of Get-SPDesignerSettings. VERBOSE: Leaving ProcessRecord Method of Get-SPDesignerSettings. VERBOSE: Leaving EndProcessing Method of Get-SPDesignerSettings. VERBOSE: Executing as the local run as user SKY\spfarm VERBOSE: Leaving BeginProcessing Method of Get-SPWebApplication. VERBOSE: Leaving ProcessRecord Method of Get-SPWebApplication. VERBOSE: Leaving EndProcessing Method of Get-SPWebApplication. -> Scanning Outgoing Email Settings [ SP ] Scanning Web Applications App Domain(s)... Get-TargetResource : A parameter cannot be found that matches parameter name 'WebApplication'. At C:\Program Files\WindowsPowerShell\Scripts\SharePointDSC.Reverse.ps1:4341 char:43
+ CategoryInfo : InvalidArgument: (:) [Get-TargetResource], ParameterBindingException
+ FullyQualifiedErrorId : NamedParameterNotFound,Get-TargetResource
Cannot index into a null array. At C:\Program Files\WindowsPowerShell\Modules\ReverseDSC\1.9.4.4\ReverseDSC.Core.psm1:257 char:17
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : NullArray
Get-TargetResource : A parameter cannot be found that matches parameter name 'WebApplication'. At C:\Program Files\WindowsPowerShell\Scripts\SharePointDSC.Reverse.ps1:4341 char:43
+ CategoryInfo : InvalidArgument: (:) [Get-TargetResource], ParameterBindingException
+ FullyQualifiedErrorId : NamedParameterNotFound,Get-TargetResource
Cannot index into a null array. At C:\Program Files\WindowsPowerShell\Modules\ReverseDSC\1.9.4.4\ReverseDSC.Core.psm1:257 char:17
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : NullArray
[ SP ] Configuring Local Configuration Manager (LCM)... Configuring Credentials... Please enter the full path of the output folder for DSC Configuration (will be created as necessary):
Having the same exception on both my 2016 and 2019 test environment. Subscription settings service is provisioned in both environment.
@xenophobentx Can you try using the latest PR from this GitHub Repo. I believe we've identified the source of the issue. Thanks
Working now! Great!
Details of the scenario you try and problem that is occurring: We've recently had a case where the extraction was throwing an error at the AppDomain extraction phase, with error message: The Microsoft Sharepoint Foundation Subscription Setting Service must be configured to complete this operation. The server somehow had App Domains registered, but had no Subscription Services Service Application. SPDSC.Reverse was trying to obtain information for the app domain from the Get-TargetResource and was throwing the error. Still unsure if this should be handled at the resource level (SPDSC) or at the Reverse level. Will need to investigate further.
The DSC configuration that is using the resource: N/A
Version of the Operating System and PowerShell the DSC Target Node is running: N/A
Version of the DSC module you're using: 3.1.1.0