Sunday, July 26, 2015

How to fix "disallowing uninstallation of component since another client exists"?

How to fix "disallowing uninstallation of component since another client exists"?

You have faced a problem when uninstallation of MSI package does not remove files?
MSI database seems to be corrupted, so I did the following:

  1. reg.exe query HKLM\Software\Microsoft\Windows\CurrentVersion\Installer\UserData /d /s /f "full or partial installation path" > reg_draft_cmd.txt
  2. findstr /C:"UserData" reg_draft_cmd.txt > reg_cmd.cmd
  3. Manually replaced "HKEY_LOCAL_MACHINE" with "REG.EXE DELETE HKEY_LOCAL_MACHINE" inside the file
  4. Run as batch file as administrator, you will need to confirm every operation. If you want silent execution, you will need to add /F into the end of every line in the batch file.