How do I determine what the Windows Installer (msiexec) is doing?

67,469

Solution 1

I'd add to the Process Explorer/Process Monitor suggestion - run FileMon and RegMon from Sysinternals too. You can filter/save a log of the msiexec and related processes, export to a csv and have a complete list of actions to the file system and registry. Compare/contrast with what has been written to the Windows Installer log, too.

You can also have a look at what Scott Willeke's Less Msiérables (LessMSI) can do for you ...

http://lessmsi.activescott.com/

Use it to extract and change guids and/or contents of MSI, repackage, check out all of the items in the MSI package, etc.

Solution 2

Get Process Monitor from Sysyinternals (MS now). Setup the filter to only watch msiexec.exe. It will tell you all that the process is doing.

Solution 3

Windows installer may spawn multiple instances of msiexec.exe for several reasons.

First of all Windows Installer features a user interface sequence (which can be skipped by running the install silently), and an installation sequence. The two tables for these sequences are called InstallUISequence and InstallExecuteSequence respectively. Due to the way Windows Installer allows "elevated rights" during installation, the InstallExecuteSequence will run as the System account. In other words if you launch the setup in GUI mode and kick of installation that way, you'll normally see two msiexec.exe processes.

Furthermore MSI files can launch custom actions - some of which can spawn new processes (EXE files). These actions may trigger further msiexec.exe processes to show up in the task manager.

Aaron Stebner has a better explanation here: https://docs.microsoft.com/en-us/archive/blogs/astebner/more-info-about-how-msi-custom-actions-work-behind-the-scenes

One more link: https://www.symantec.com/connect/blogs/multiple-msiexec-processes-running-during-installation

Solution 4

If you have control on the installation package, you can activeate the logging of the msiexec. Look at "The Command-Line Options for the Microsoft Windows Installer Tool Msiexec.exe"

Share:
67,469

Related videos on Youtube

Fox32
Author by

Fox32

Updated on September 17, 2022

Comments

  • Fox32
    Fox32 over 1 year

    After rolling out a new software package, I'm seeing high CPU usage on machines. One process that seems to be really active is msiexec, which really shouldn't be running. I'm watching it in process explorer and every now and then I can see it launching new processes that I can tell are related to the new software...but the processes end rather quickly.

    Is there any way to get some specifics on what the Windows Installer is currently up to?

    • Stein Åsmul
      Stein Åsmul about 10 years
      See my answer in the thread. If msiexec.exe pops up and then ends rather quickly the Windows Installer engine has probably run a custom action inside the MSI being installed. In other words a piece of custom code to get the application set up correctly.
  • Srinivasan MK
    Srinivasan MK almost 15 years
    Process Monitor encapsulates all the functionality of FileMon and RegMon into one app.
  • dmoisan
    dmoisan almost 15 years
    And RegMon/Filemon will be discontinued at the end of the month.