The Microsoft Software Installer (MSI) provides the ability to
return a system to its fully working condition after a failed installation.
MSI does this by maintaining an undo operation for every standard
action it performs during an install, upgrade, or uninstall. This
operation includes restoration of deleted or overwritten files, registry
keys, and other resources. Windows temporarily saves all files that
it deletes or overwrites during the course of an installation or removal,
so that they can be restored if necessary, which is a type of rollback.
After a successful installation, Windows deletes all of the temporary
backup files.
In addition to the rollback of MSI Standard Actions, the library
also has the ability to undo commands listed in the INI file for each
application if a rollback occurs. All files that are modified by the
installation actions are restored to their original state if a rollback
occurs.
When the MSI engine is going through the installation sequence,
it ignores all actions that are scheduled as rollback actions. If
a Custom Action, MSI Standard Action, or a installation action fails,
then a rollback starts.
You cannot roll back an installation once it is completed; transacted
installation is only intended as a safety net that protects the system
during an installation session. If you want to remove an installed
application, you should uninstall that application.
-
NOTE: Driver installation
and removal is not executed as part of the installation transaction
and therefore cannot be rolled back if a fatal error occurs during
execution.
-
NOTE: Installations,
uninstallations, and upgrades that you cancel during installer cleanup,
or after the installation transaction is completed, are not rolled
back.