A Clean Slate

 

We often get questions about uninstalling software remotely. We will be providing this capability in version 2.0, but until then there are ways to get what you want done.

Method 1

The first and simplest way to uninstall remotely only works if the application was installed with a .msi file and you have access to the install file. You simply “deploy” the .msi file with Admin Arsenal using the Uninstall option:

MSI Uninstall Option
MSI Uninstall Option

Admin Arsenal will then go through the standard deployment process, except that it will uninstall the application.

Method 2

The second method is a bit more tricky, but doable. It is this process that Admin Arsenal version 2.0 will automate for you. What you need to find is the “Uninstall String” which is the command that is run by the Add/Remote Programs control panel when you want to uninstall a program. This is located in the registry on the computer where the application is installed. 

To find the uninstall string, navigate to the following key:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
Uninstall Registry Key
Uninstall Registry Key

Within this key there will be entries for the programs that are installed. It may be a bit tricky to find exactly the one you’re looking for, but using search should help you get to it. Most entries will have an UninstallString value. This is the value you want. In the highlighted example above, the value is:

"C:\Program Files\TightVNC\unins000.exe"

Running this command will give you exactly what you get when running the Add/Remove Programs control panel. The same caveats about silent installations applies to uninstalling as installing. If you ran this uninstall string, as it is, remotely it would hang and never finish. This is because it pops up asking if you “really, honest to goodness, pinky swear want to uninstall?” but the question won’t be visible to allow you to answer.

A quick search in for “unins000.exe silent” in [your search engine of choice] revealed that if you use /silent as the argument, you’ll avoid the question and the install runs without user intervention.

"C:\Program Files\TightVNC\unins000.exe" /silent

Tip:  Some uninstall strings include MsiExec.exe. These always have the same options to uninstall quietly. Simply change a value like this:

MsiExec.exe /I{3EE9BCAE-E9A9-4535-9B1C-83A4D357E05C}

to this:

MsiExec.exe /X{3EE9BCAE-E9A9-4535-9B1C-83A4D357E05C} /q

Now that you have the uninstall string, you just need to run it as a remote command, and voilà, a clean slate.