Every once in a while I need to extract the content of a .msi file in order to customize a deployment for a particular network environment. Sometimes initializing the .msi installer will temporarily extract the files into C:\Documents and Settings\<username>\Local Settings\Temp, but those files are removed once the installer exits.

To extract files from a .msi file at the command line, type:

Table of Contents

    msiexec /a PathToMSIFile /qb TARGETDIR=DirectoryToExtractTo

    For example, to extract files from f:\zenworks\zfdagent.msi into c:\zfd701 you would type:

    msiexec /a f:\zenworks\zfdagent.msi /qb TARGETDIR=c:\zfd701

    The destination directory does not need to exist prior to running this command.

    [update 05-20-2009]

    I have a new favorite MSI extraction tool called LessMSIerables.  Check it out!

    Leave a Reply

    Your email address will not be published. Required fields are marked *