With Sitecore 9.2 and above, Uninstalling Sitecore has never been much easier. The Uninstall-SitecoreConfiguration SIF PS Module Commandlet does a clean uninstall of the respective configurations installed on your workstation/server.
Here is the Command line for your reference:
Uninstall-SitecoreConfiguration @singleDeveloperParams *>&1 | Tee-Object XP0-SingleDeveloper-Uninstall.log
This comes up as a commented line in the respective SP Configuration Install PS1 script in the corresponding Installation Package. ex. XP0-SingleDeveloper.ps1
During the uninstall process, you could see the following activities being performed:
- Stop Websites
- Stop App Pool
- Remove App Pool
- Remove Website
- Remove Content (if any)
- Remove Host Headers
- Remove Databases
- Remove Solr Cores
- Stop Windows Service – Index Worker
- Stop Windows Service – Marketing Automation Service
- Stop Windows Service – Processing Engine Service
- Remove Windows Service – Index Worker
- Remove Windows Service – Marketing Automation Service
- Remove Windows Service – Processing Engine Service
- Remove Registry Entries
Note: Above steps are repeated for Sitecore, XConnect and Identity Server instances.
However, during this uninstall operation, the Certificates created still remain in your Windows Certificate Store. To uninstall these certificates, you can perform the following operation:
- Open up Microsoft Management Console (MMC)
- File –> Add/Remove Snap-in.
- Select “Certificates” –> Next –> “Computer Account” –> Next –> Finish –> OK
- Navigate to “Personal” –> “Certificates” folder and observe the Sitecore Certificates as shown below:
You can select all Sitecore-specific certificates pertaining to the instance being uninstalled, right-click and delete.
Here is the reference of all Certificate Paths:
PFX Certificate files are stored in the following path:
C:\Sitecore (defined by the install configurations path)
Now you have a clean Sitecore 9.2+ uninstall!
Hope this helps!