TOP KEK
TOP KEK

Reputation: 2661

How does uninstall process work in windows?

When I'm uninstalling a program from control panel how does it know what components and features are installed on the machine? If I have the .msi file I can use ORCA to take a look inside windows installer database and see all the actions and components in the package. But if user have deleted .msi file then how does windows installer knows about installed features?

Upvotes: 1

Views: 2888

Answers (1)

Christopher Painter
Christopher Painter

Reputation: 55601

During the installation, a copy of the MSI ( smaller because it's been stripped of media ) is cached in the C:\Windows\Installer directory using a short hash filename. (example: a60a04.msi ) Also when the standard actions PublishComponents, PublishFeatures and PublishProduct are run during the installation a bunch of meta is written to HKEY_CLASSES_ROOT\Installer ( actually HKLM or HKCU depending on the ALLUSERS property ). The Windows Installer uses all of this information to have an understanding of the installed products and to know how to perform repair, resilience, maintenance (add/remove features) and uninstalls. It's also used by the MSI API to provide information when requested.

Upvotes: 3

Related Questions