V2. Uninstall an ArcGIS Enterprise deployment - Esri/arcgis-powershell-dsc GitHub Wiki

If you want to uninstall an ArcGIS Enterprise deployment you had installed using the PowerShell DSC Module, you can do so by running the same command as for installation. Note that uninstalling is not required in order to upgrade your deployment to a new version; the PowerShell DSC Module is capable of running an in-place upgrade using the Configure-ArcGIS cmdlet.

Learn how to upgrade ArcGIS Enterprise with the PowerShell DSC Module (link)

Uninstall a deployment

Retrieve your JSON configuration file(s). Unlike with installation or upgrade, you do not need to modify your JSON configuration file(s) before running an uninstall. The JSON configuration files you provide to the cmdlet as an input parameter should be identical to what you provided at install time.

In PowerShell DSC, run the Configure-ArcGIS cmdlet and provide the JSON configuration files as an input parameter. If you have multiple configuration files, provide them in a comma-separated list. Credential is an optional argument.

 Configure-ArcGIS -ConfigurationParametersFile [Path to Configuration JSON File(s)](/Esri/arcgis-powershell-dsc/wiki/Path-to-Configuration-JSON-File(s)) -Mode Uninstall -Credential [Config RunAs - Optional]

The cmdlet will uninstall all software and remove all ArcGIS Enterprise system files from your machine.