I’ve done a deployment and I’ve installed on “Local” without problems.
Then I have published the deployment from SCCM and when I try to do the installation from Software Centre I received this error 0xEA62(60002).
This is the deployment that Works executing deploy-application.exe directly on one computer.
[CmdletBinding()]
Param (
[Parameter(Mandatory=$false)]
[ValidateSet('Install','Uninstall')]
[string]$DeploymentType = 'Install',
[Parameter(Mandatory=$false)]
[ValidateSet('Interactive','Silent','NonInteractive')]
[string]$DeployMode = 'Interactive',
[Parameter(Mandatory=$false)]
[switch]$AllowRebootPassThru = $false,
[Parameter(Mandatory=$false)]
[switch]$TerminalServerMode = $false,
[Parameter(Mandatory=$false)]
[switch]$DisableLogging = $false
)
Try {
## Set the script execution policy for this process
Try { Set-ExecutionPolicy -ExecutionPolicy 'ByPass' -Scope 'Process' -Force -ErrorAction 'Stop' } Catch {}
##*===============================================
##* VARIABLE DECLARATION
##*===============================================
## Variables: Application
[string]$appVendor = 'Microsoft'
[string]$appName = 'Dynamics CRM'
[string]$appVersion = ''
[string]$appArch = ''
[string]$appLang = 'ES'
[string]$appRevision = '01'
[string]$appScriptVersion = '1.0.0'
[string]$appScriptDate = '02/12/2017'
[string]$appScriptAuthor = 'Haide Pulido'
[string]$appCloseApps = 'iexplore,outlook'
##*===============================================
## Variables: Install Titles (Only set here to override defaults set by the toolkit)
[string]$installName = ''
[string]$installTitle = ''
##* Do not modify section below
#region DoNotModify
## Variables: Exit Code
[int32]$mainExitCode = 0
## Variables: Script
[string]$deployAppScriptFriendlyName = 'Deploy Application'
[version]$deployAppScriptVersion = [version]'3.7.0'
[string]$deployAppScriptDate = '02/13/2018'
[hashtable]$deployAppScriptParameters = $psBoundParameters
## Variables: Environment
If (Test-Path -LiteralPath 'variable:HostInvocation') { $InvocationInfo = $HostInvocation } Else { $InvocationInfo = $MyInvocation }
[string]$scriptDirectory = Split-Path -Path $InvocationInfo.MyCommand.Definition -Parent
## Dot source the required App Deploy Toolkit Functions
Try {
[string]$moduleAppDeployToolkitMain = "$scriptDirectory\AppDeployToolkit\AppDeployToolkitMain.ps1"
If (-not (Test-Path -LiteralPath $moduleAppDeployToolkitMain -PathType 'Leaf')) { Throw "Module does not exist at the specified location [$moduleAppDeployToolkitMain]." }
If ($DisableLogging) { . $moduleAppDeployToolkitMain -DisableLogging } Else { . $moduleAppDeployToolkitMain }
}
Catch {
If ($mainExitCode -eq 0){ [int32]$mainExitCode = 60008 }
Write-Error -Message "Module [$moduleAppDeployToolkitMain] failed to load: `n$($_.Exception.Message)`n `n$($_.InvocationInfo.PositionMessage)" -ErrorAction 'Continue'
## Exit the script, returning the exit code to SCCM
If (Test-Path -LiteralPath 'variable:HostInvocation') { $script:ExitCode = $mainExitCode; Exit } Else { Exit $mainExitCode }
}
#endregion
##* Do not modify section above
##*===============================================
##* END VARIABLE DECLARATION
##*===============================================
If ($deploymentType -ine 'Uninstall') {
##*===============================================
##* PRE-INSTALLATION
##*===============================================
[string]$installPhase = 'Pre-Installation'
## Show Welcome Message, close Internet Explorer if required, allow up to 3 deferrals, verify there is enough disk space to complete the install, and persist the prompt
Show-InstallationWelcome -CloseApps $appCloseApps -CheckDiskSpace -PersistPrompt
## Show Progress Message (with the default message)
Show-InstallationProgress
## <Perform Pre-Installation tasks here>
##*===============================================
##* INSTALLATION
##*===============================================
[string]$installPhase = 'Installation'
## Handle Zero-Config MSI Installations
If ($useDefaultMsi) {
[hashtable]$ExecuteDefaultMSISplat = @{ Action = 'Install'; Path = $defaultMsiFile }; If ($defaultMstFile) { $ExecuteDefaultMSISplat.Add('Transform', $defaultMstFile) }
Execute-MSI @ExecuteDefaultMSISplat; If ($defaultMspFiles) { $defaultMspFiles | ForEach-Object { Execute-MSI -Action 'Patch' -Path $_ } }
}
## <Perform Installation tasks here>
Execute-Process -path 'CRM2016-Client-ESN-i386.exe' -parameters '/quiet /extract:c:\Temp\CRMforOutlook'
Execute-Process -path 'c:\Temp\CRMforOutlook\SetupClient.exe' -parameters '/Q /installofflinecapability'
Copy-File -Path "$dirSupportFiles\config.xml" -destination "C:\Program Files (x86)\Microsoft Dynamics CRM\" -recurse
Execute-Process -path 'C:\Program Files (x86)\Microsoft Dynamics CRM\Client\ConfigWizard\Microsoft.Crm.Application.Outlook.ConfigWizard.exe' -parameters '/Q /i "C:\Program Files (x86)\Microsoft Dynamics CRM\config.xml"'
##*===============================================
##* POST-INSTALLATION
##*===============================================
[string]$installPhase = 'Post-Installation'
## <Perform Post-Installation tasks here>
## Display a message at the end of the install
If (-not $useDefaultMsi) { Show-InstallationPrompt -Message 'You can customize text to appear at the end of an install or remove it completely for unattended installations.' -ButtonRightText 'OK' -Icon Information -NoWait }
}
ElseIf ($deploymentType -ieq 'Uninstall')
{
##*===============================================
##* PRE-UNINSTALLATION
##*===============================================
[string]$installPhase = 'Pre-Uninstallation'
## Show Welcome Message, close Internet Explorer with a 60 second countdown before automatically closing
Show-InstallationWelcome -CloseApps 'iexplore' -CloseAppsCountdown 60
## Show Progress Message (with the default message)
Show-InstallationProgress
## <Perform Pre-Uninstallation tasks here>
##*===============================================
##* UNINSTALLATION
##*===============================================
[string]$installPhase = 'Uninstallation'
## Handle Zero-Config MSI Uninstallations
If ($useDefaultMsi) {
[hashtable]$ExecuteDefaultMSISplat = @{ Action = 'Uninstall'; Path = $defaultMsiFile }; If ($defaultMstFile) { $ExecuteDefaultMSISplat.Add('Transform', $defaultMstFile) }
Execute-MSI @ExecuteDefaultMSISplat
}
# <Perform Uninstallation tasks here>
##*===============================================
##* POST-UNINSTALLATION
##*===============================================
[string]$installPhase = 'Post-Uninstallation'
## <Perform Post-Uninstallation tasks here>
}
##*===============================================
##* END SCRIPT BODY
##*===============================================
## Call the Exit-Script function to perform final cleanup operations
Exit-Script -ExitCode $mainExitCode
}
Catch {
[int32]$mainExitCode = 60001
[string]$mainErrorMessage = "$(Resolve-Error)"
Write-Log -Message $mainErrorMessage -Severity 3 -Source $deployAppScriptFriendlyName
Show-DialogBox -Text $mainErrorMessage -Icon 'Stop'
Exit-Script -ExitCode $mainExitCode
}
When I try from Software Centre It seems that this step doesn’t work :
Execute-Process -path 'c:\Temp\CRMforOutlook\SetupClient.exe' -parameters '/Q /installofflinecapability'
Log:
<![LOG[[Installation] :: [CRM2016-Client-ESN-i386.exe] successfully resolved to fully qualified path [C:\Windows\ccmcache\k\Files\CRM2016-Client-ESN-i386.exe].]LOG]!><time="16:25:33.99960" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Working Directory is [C:\Windows\ccmcache\k\Files].]LOG]!><time="16:25:34.26860" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Executing [C:\Windows\ccmcache\k\Files\CRM2016-Client-ESN-i386.exe /quiet /extract:c:\Temp\CRMforOutlook]...]LOG]!><time="16:25:34.32260" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Execution completed successfully with exit code [0].]LOG]!><time="16:27:58.79760" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: [c:\Temp\CRMforOutlook\SetupClient.exe] is a valid fully qualified path, continue.]LOG]!><time="16:27:58.82260" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Working Directory is [c:\Temp\CRMforOutlook].]LOG]!><time="16:27:58.84460" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Executing [c:\Temp\CRMforOutlook\SetupClient.exe /Q /installofflinecapability ...]LOG]!><time="16:27:58.86960" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Execution completed successfully with exit code [0].]LOG]!><time="16:28:24.14960" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Destination folder does not exist, creating destination folder [C:\Program Files (x86)\Microsoft Dynamics CRM\].]LOG]!><time="16:28:24.19060" date="12-18-2018" component="Copy-File" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Copy file(s) recursively in path [C:\Windows\ccmcache\k\SupportFiles\config.xml] to destination [C:\Program Files (x86)\Microsoft Dynamics CRM\].]LOG]!><time="16:28:24.22260" date="12-18-2018" component="Copy-File" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: File copy completed successfully.]LOG]!><time="16:28:24.26260" date="12-18-2018" component="Copy-File" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: [C:\Program Files (x86)\Microsoft Dynamics CRM\Client\ConfigWizard\Microsoft.Crm.Application.Outlook.ConfigWizard.exe] is a valid fully qualified path, continue.]LOG]!><time="16:28:24.28760" date="12-18-2018" component="Execute-Process" context="NT AUTHORITY\SYSTEM" type="1" thread="6240" file="Deploy-Application.ps1">
<![LOG[[Installation] :: Function failed, setting exit code to [60002].
Error Record:
-------------