Whenever you install a piece of software in Windows, most of the time it will come with its own dedicated uninstaller that allows you to safely remove the program from your computer. This is because software nowadays is becoming more and more complex and requires registering OCX or DLL files, adding or changing registry keys, installing driver files, dropping files into the appropriate places and etc. There are many types of installers around such as InstallShield, InnoSetup, Wise and NSIS. Another popular one is Windows Installer which uses .MSI files and several developers such as Kaspersky use it to pack their software for users to install and uninstall.
If you’ve installed some software and suddenly Windows has stopped working or become unstable, the logical thing to do is boot Windows into Safe Mode and then try to uninstall from there. Security software sometimes requires Safe Mode to completely remove itself because protected files are in use in normal mode. Only the basic files and drivers necessary to run Windows are started in Safe Mode, and unfortunately, by default you can’t uninstall any software that is packaged with Windows Installer. If you try to uninstall, you will get the error similar to this (Windows XP has a slightly different message):
The Windows Installer service is not accessible in Safe Mode. Please try again when your computer is not in Safe Mode or you can use System Restore to return your machine to a previous good state.
There is a Windows Installer service called MSIServer listed in the Services Control Panel applet, and if you boot directly into Safe Mode then attempt to manually start the Windows Installer service, you will receive the following error:
Windows could not start the Windows Installer service on Local Computer.
Error 1084: This service cannot be started in Safe Mode.
Thankfully all is not lost and it’s actually very easy to enable the Windows Installer service in Safe Mode so that you can uninstall programs, all you need to do is add a new MSIServer registry key for Safe Mode. This can be done from either Safe Mode or Normal Mode, it doesn’t matter as enabling the registry key will take effect immediately. There’s a little utility that’s been around since 2005 that can do the same thing called SafeMSI by Harry Bates over at WindowsITPro.com. It will add the registry entries and start the service (it will start automatically anyway).
Simply launch the program and it will popup a box to say it’s been enabled. This can be launched in Safe or Normal Mode, and although made back in 2005, still works for newer operating systems because the created registry keys have never changed.
Alternatively, simply follow the instructions below, the procedure is the same for Windows XP, Vista, 7 and 8:
1. Hit Win+R, type regedit and click OK.
2. Navigate to the following location in registry editor:
3. Right click on Minimal and select New -> Key and name it MSIServer.
4. The (Default) data for the MSIServer key should show (value not set). Double click on (Default) and type Service in the value data. Close the Registry Editor.
There are actually two registry keys that can be changed, the above is for the standard Safe Mode. To enable the MSIServer service in Safe Mode with networking as well, you can perform the same procedure on this registry key also:
It’s should now be possible to install or uninstall MSI programs that are packed using Windows Installer in Safe Mode. Thankfully the Windows Installer service is setup as Manual by default so it will not start until called upon. For ease of use, we’ve made a simple registry .reg file which you can double click on to import these values into the registry automatically.