5

I was following Quick Installation Guide available here to uninstall my fresh Sitecore 9.1 instance.

It says in chapter 4.2. Uninstall the XP Single topology this:


To uninstall any of the Sitecore XP topologies, change the Install-SitecoreConfiguration cmdlet to Uninstall-SitecoreConfiguration.

For example: Change Install-SitecoreConfiguration @XP1Parameters *>&1 | Tee-Object XP1- SingleDeveloper.log to Uninstall-SitecoreConfiguration @XP1Parameters *>&1 | Tee-Object XP1- SingleDeveloper-Uninstall.log

Run the script and the topology is removed.


I have done exactly that:

enter image description here

This is the exact code:

#Install-SitecoreConfiguration @singleDeveloperParams *>&1 | Tee-Object XP0-SingleDeveloper.log

# Uncomment the below line and comment out the above if you want to remove the XP0 SingleDeveloper Config
Uninstall-SitecoreConfiguration @singleDeveloperParams *>&1 | Tee-Object XP0-SingleDeveloper-Uninstall.log

I have uncommented what was needed to and commented what I had to.

But getting this error:

Uninstall-SitecoreConfiguration : No registration found for extension 'RemoveSQLDatabase' of type 'Task'. At C:\ResourceFiles\03_UninstallSitecore_XP0-SingleDeveloper.ps1:77 char:1 + Uninstall-SitecoreConfiguration @singleDeveloperParams *>&1 | Tee-Obj ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Install-SitecoreConfiguration

[TIME] 00:00:01

MapTasks : No registration found for extension 'RemoveSQLDatabase' of type 'Task'. At C:\Program Files\WindowsPowerShell\Modules\SitecoreInstallFramework\2.0.0\Public\Install-SitecoreConfiguration.ps1:453 char:28 + ... sksConfig = MapTasks -InputObject $rawConfig -TasksToExecute $tasksTo ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,MapTasks

This is how it looks in Powershell in full length:

enter image description here

Any thoughts?

I have already run Update-Module SitecoreInstallFramework to have up to date SIF.

3 Answers 3

10

You are missing the SQLServer module.

Either run the prerequisites.json file which will install that and any missing prerequisites or:

Install-Module -Name SQLServer if you are just missing the SQL server module.

3
  • I have already run prerequisites.json during installation. I have received this error when running command suggested by you in your answer: PackageManagement\Install-Package : A command with name 'Decode-SqlName' is already available on this system. This module 'SqlServer' may override the existing commands. If you still want to install this module 'SqlServer', use -AllowClobber parameter. At C:\Program Files\WindowsPowerShell\Modules\PowerShellGet\1.0.0.1\PSModule.psm1:1772 char:21..... Dec 3, 2018 at 8:51
  • 1
    My guess is that you have SQL installed locally on your machine? This isn't a problem, however an old SQL module called SQLPS will be there that causes that error. I would suggest you run two things. Your PowerShellGet module is out of date, so run "Update-Module -name PowerShellGet" and then "Install-Module -Name SQLServer -AllowClobber -Force" which will override the SQLPS module. Dec 3, 2018 at 9:01
  • Thanks for helping me Richard. At the end I have run prerequisites first, close Powershell command window and rerun instainstall script. Seems that uninstall script did not recognized new SQLServer module ... Dec 3, 2018 at 9:15
5

I have fixed this by:

  1. Rerunning Install-SitecoreConfiguration -Path .\Prerequisites.json . Not sure why first run was not successful. Could be that I have forgotten to run it before installing first Sitecore 9.1 instance... Can't remember precisely as it was during release night :)
  2. Closing Powershell command prompt (to make changes / updates in step 1 take in account)
  3. Rerunning uninstall ps1 script as mentioned in answer
2

Douglas Couto shared a different solution on his blog that has also worked for me. Some computers seems to have access right issues.

When calling the SIF command, use the ByPass ExecutionPolicy.

Examples:

  • powershell -ExecutionPolicy ByPass Install-SitecoreConfiguration -Path .\Prerequisites.json
  • powershell -ExecutionPolicy ByPass Uninstall-SitecoreConfiguration @XP1Parameters *>&1 | Tee-Object XP1-SingleDeveloper-Uninstall.log

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.