Install MSI Packages With Logging via the Right-Click Menu

When a software installation that uses the Windows Installer Package fails, you enable Windows Installer logging and re-run the setup to capture the output to a log file for troubleshooting. Logging can be done using the Registry Editor, the Group Policy Editor, or the msiexec.exe command with the required parameters.

The first two methods are documented in the article How to Enable Windows Installer Logging. The third method uses the msiexec.exe command-line parameter. Here is an example:

msiexec /l*v "%temp%\verbose.log" /i "C:\Users\Ramesh\Downloads\7z465-x64.msi"

This starts the 7-Zip .msi installation (7z465-x64.msi) and records all the results, including verbose output, to a log file named verbose.log in the %TEMP% folder.

Do you find it difficult to type the entire command-line every time you need to log application setups? You can implement this in the context menu for .msi files to launch the installation with verbose logging.

Add “Install (with Logging)” to .MSI Context Menu

  1. Create a folder named “Log” on the C: drive — i.e., C:\Log.
  2. Launch the Registry Editor by running regedit.exe.
  3. Navigate to the following branch:
    HKEY_CLASSES_ROOT\Msi.Package\shell\
  4. Create a subkey named Open2.
  5. Select Open2, and set the (default) value to Install (with logging).
    .msi with logging context menu - registry
  6. Under Open2, create a subkey named command.
  7. Select command, and set the (default) value as follows:
    msiexec.exe /l*v "C:\Log\verbose.log" /i "%1" %*

    .msi with logging context menu - registry

    Note: The log file path is set as “C:\Log\verbose.log” in the above example. You may change the output file name and path accordingly if needed. However, ensure that the path exists. That existing log file with the same name will be replaced. If you need to append data to the existing log file, you need to include an additional command-line switch.

  8. Exit the Registry Editor.
  9. This adds the Install (with logging) option to the right-click menu for .msi files.
    .msi with logging context menu - registry
  10. Now, right-click on the software package you want to install with logging, and click Install (with logging).This starts the installation with logging. To confirm, you can check the msiexec.exe process and its command-line in Task Manager. (Ref: Configure Task Manager to display full path of running processes)

    .msi with logging - taskmgr

  11. After the setup completes, open the log file (“C:\Logs\verbose.log”) to analyze what went wrong during the setup..msi with logging

    .msi with logging

If you receive the following error message when clicking on the “Install (with logging)” context menu, it means the log file path specified in the registry is missing. To fix the problem, create the folder you mentioned in the registry, i.e., C:\Log, in this example.

Error opening installation log file.  Verify that the specified log file location exists and is writable.

msi logging error path not found


Reading a Windows Installer log file

Analyzing and interpreting a Windows Installer log is another skill. For more information on working with Windows Installer logs, check out the following articles:



Richard’s Weblog: How to Interpret Windows Installer Logs

Windows Installer: Reading a Windows Installer log file.

Windows Installer Log File – How to read, analyze, and debug it

Wilogutl.exe – Win32 apps | Microsoft Learn


One small request: If you liked this post, please share this?

One "tiny" share from you would seriously help a lot with the growth of this blog. Some great suggestions:
  • Pin it!
  • Share it to your favorite blog + Facebook, Reddit
  • Tweet it!
So thank you so much for your support. It won't take more than 10 seconds of your time. The share buttons are right below. :)

Ramesh Srinivasan is passionate about Microsoft technologies and he has been a consecutive ten-time recipient of the Microsoft Most Valuable Professional award in the Windows Shell/Desktop Experience category, from 2003 to 2012. He loves to troubleshoot and write about Windows. Ramesh founded Winhelponline.com in 2005.

Leave a Comment