Windows Installer Errors 2503 & 2502: Called RunScript when not marked in progress & Called InstallFinalize when no install in progress

This is a quick post on how to troubleshoot situations where you get error 2503 (Called RunScript when not marked in progress) followed by error 2502 (Called InstallFinalize when no install in progress) when trying to install or uninstall software with Windows Installer.

Situation

When you try to install or uninstall an MSI package (thus invoking Windows Installer), you get two errors in the following order:

  1. Error 2503: Called RunScript when not marked in progress
  2. Error 2502: Called InstallFinalize when no install in progress

Troubleshooting Strategy

When you search for Windows Installer (MSI) errors 2503 and 2502, you find many articles that mention file system permission issues as the cause. To figure out where exactly permissions could be missing, I created a Process Monitor trace of the system activity and filtered for msiexec.exe errors. This is what I got:

Analysis

Windows Installer (msiexec.exe) tries to create a TMP file in C:\Windows\Temp, which fails with Access denied. The reason for the failure is that it tries to create the file while non-elevated, in other words, with standard user permissions. Standard users don’t have write permissions in C:\Windows\Temp by default, though.

Solutions/Workarounds

In my case, I believe the root cause was an issue with the MSI package, which needs to be fixed by the software vendor that authored it. There are, however, workarounds:

Workaround 1: Elevate

Don’t rely on the installer to elevate at the right point in time. Start the installer with elevated rights yourself, e.g., from an elevated command prompt.

Workaround 2: Temporarily Assign Write Permissions

Temporarily assign write permissions to C:\Windows\Temp. This is easy with my free tool SetACL Studio.

Tip: don’t modify an existing ACE (permissions entry), e.g., for the group Users. Instead, add a new ACE for your user account. This makes it easier to reverse your changes afterwards.

Comments

Related Posts

Obsidian: Getting Started With the Markdown Note-Taking App

Obsidian: Getting Started With the Markdown Note-Taking App
Ever since the original Microsoft OneNote was discontinued I’ve been on the lookout for my ideal note-taking app. Having settled on Markdown as the perfect file format I’ve tried numerous apps and occasionally blogged about the experience. In my quest to find the app that combines a great UX with elegant esthetics, speed and full keyboard control I’ve recently settled on a combination of Typora and Obsidian - none of which are perfect, but both are satisfying tools to use and they even complement each other. This article explains how to get started with Obsidian.
Applications

Latest Posts