MAKEMSI quickly and reliably creates MSI files in a non-programmatic way
Have your say! Join the MAKEMSI discussion list or view archive! Suggest improvements. No question too simple or too complex.
[Bottom][Contents][Prev]: Bootstrapper EXE Programs[Next]: Components
Have your say! Join the MAKEMSI discussion list or view archive! Suggest improvements. No question too simple or too complex.
\->Windows Installer FAQ (the basics)->Caching Of MSIs, patches etc

Windows Installer Basics: Caching Of MSIs, patches etc

After Windows Installer has installed your msi (or patch) it caches it in the hidden directory "%WinDir%\Installer". The name of the cached msi will be randomly changed to something like "2b2d4b.msi". Subdirectories typically contain shortcut and product icons.

The cached msi is stripped of any files it may have contained to reduce its size, but this still allows most repairs (depending on how the MSI is designed) to occur without the need to prompt a user for the original media (which they then need to locate). See the "Source Availability" section for more details (including why Windows Installer may need to prompt for media anyway).

If you don't want to cache your MSI and don't need uninstall support then the "No Installation Registration" tip is for you! If you need uninstall support but you have an extremely large msi (not counting any files it may contain) you could try scheduling a custom action after the Windows Installer registration to determine the cached filename and then delete it.

Install of MSI with Transform...

This is what I have observed:

  1. The complete msi and transforms are moved to the cache (with randomish filenames), at this time they retain their date/time and size information.

  2. The "DATABASE" property points to the msi but there is nothing to point to the transform (a mistake if you ask me).

  3. The installation proceeds and ends.

  4. The files are stripped.

Microsoft's Take on Caching...

Eric Tam (29 Sept 2000) posted a response from Microsoft on caching:

I understand you have a question about the Windows Installer and the
WINNT/Installer directory.  The fact that Windows Installer caches a MSI to
this directory is by design.  When you run a Windows Installer package runs,
the package gets cached to the directory mentioned above.  MSI does this in
order for maintenance mode and resiliency to work properly.  Maintenance
mode uses this cached package whenever someone goes to the Add/Remove
Programs in the Control Panel to change the installation state of features.
Resiliency uses the cached package anytime a file, directory, registry keys,
registry values, or registry names.  Even if you uninstall your application,
the cached package will still remain in the Winnt\Installer directory.

The architects of Windows Installer felt caching the package was a good
feature/disk space trade-off.  They felt that since the average MSI package
is only a couple of MB's and disk space is so cheap, that the extra disk
space used for these features was worth the trade-off.

There is no switch or setting available to turn this feature off, but it is
safe to delete any of the MSI files or the whole directory.  If you do
delete the directory or the MSI files, you will be prompted for the original
source if you add any features in maintenance mode or if the resiliency
feature activates.

As subdirectories contain shortcut and product icons, I doubt it is a good idea to deleted everything as mentioned above.


Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.Please email me any feedback, additional information or corrections.
See this page online (look for updates)

[Top][Contents][Prev]: Bootstrapper EXE Programs[Next]: Components


MAKEMSI© is (C)opyright Dennis Bareis 2003-2008 (All rights reserved).
Sunday February 28 2016 at 3:45pm
Visit MAKEMSI's Home Page
Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.