Windows_Installer Windows_Installer

Windows Installer - Definition and Overview

The Windows Installer (previously known as Microsoft Installer, codename Darwin) is an engine for the installation of programs on Microsoft Windows systems. The installation information, and often the files themselves, are packaged in installation packages, loosely relational databases structured as OLE Compound Storage Files and commonly known as "MSI files", from their default extension (compare: .deb, RPM). Windows Installer is a significant improvement over its predecessor, Setup API: several new features, such as a GUI framework, the automatic generation of the uninstallation sequence and the powerful deploying capabilities, made Windows Installer a viable alternative to stand-alone executable installer frameworks such as older versions of InstallShield and WISE (later versions are based on Windows Installer).

Third parties are encouraged to use Windows Installer as the basis for installation frameworks, so that they synchronize correctly with other installers and keep the internal database of installed products consistent. Important features such as rollback and versioning (see DLL Hell) depend on a consistent internal database for reliable operation.

Contents

Logical structure of packages

A package describes the installation of a full product (Windows Installer doesn't handle dependencies between products) and is universally identified by a GUID. A product is made up of components, grouped in features.

Components

A component is the minimal part of a product - each component is treated by Windows Installer as a unit. Components can be files, groups of files, directories, COM components, registry keys or shortcuts. They are generally not user-visible. They are identified globally, by GUIDs, thus the same component can be shared among several packages (altough, for this to work correctly, different components shouldn't share any sub-component).

Features

A feature is a hierarchical group of components - it can contain any number of components and other features. An example of feature would be a spell checker. They are user-visible, and usually a list of them is presented to the user so that the desired ones can be chosen. Features are identified locally to the containing product, by character strings.

Setup phases

Acquisition

In this phase, Windows Installer receives instructions, from an user or an application, to install or uninstall features of a product. The requests cause the execution of sequences of actions, which query the installation database to build a script describing the execution phase in detail.

Execution

In this phase, the script built in the previous phase is executed in the context of the privileged Windows Installer service. The script has to be executed by a privileged service because of the etherogeneity of the scenarios in which a setup operation is initiated - for example, it's necessary to serve on-demand installation requests from non-privileged users.

Rollback

In case any script action fails, or the operation is cancelled by the user, all the actions performed until that point are rolled back, restoring the system to its original state.

Other features

Advertisement

Windows Installer can advertise a product rather than actually installing it. The product will appear installed to the user, but it will not actually be installed until it's run for the first time (either by means of a Start menu icon or by opening a document that the product is configured to handle).

Installation on demand

Similar to advertisement, it consists in the installation of features as soon as the user tries to use them.

Miscellaneous

Windows Installer allows to run applications directly from a network share instead of copying them locally (run from source); it can repair broken installations by restoring damaged or deleted files and registry entries; it can resolve component identifiers into paths, allowing applications not to rely on hard-coded paths; and it natively supports patches and other customizations of packages through manipulations (transforms and merges) of a package's relational database.

It's also unique among other installation software for Windows for its transparency: the full API and command line options are documented; packages are freely viewable and editable, both with free tools and programmatically (as opposed to the proprietary and even weakly encrypted packages of InstallShield); the format for file archives is the well documented Microsoft Cabinet; and detailed logging is supported, as a powerful diagnostic tool.

External links

Information and tools from Microsoft

  • The Microsoft MSI (http://www.microsoft.com/windows2000/community/centers/management/msi_faq.mspx) FAQ
  • The MSI SDK (http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=E96F8ABC-62C3-4CC3-93AD-BFC98E3AE4A3)
  • Windows installer start page (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/windows_installer_start_page.asp)
  • Other sources of windows installer information (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/other_sources_of_windows_installer_information.asp)
  • Get the latest version (http://www.microsoft.com/msdownload/platformsdk/sdkupdate/downlevel.htm) of the MS Windows SDKs including the MSI SDK

Tools for creating MSI files from other vendors

Community sites

Copyright 2009 WordIQ.com - Privacy Policy  :: Terms of Use  :: Contact Us  :: About Us
This article is licensed under the GNU Free Documentation License. It uses material from the this Wikipedia article.