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

Fixing VS Code UI Unresponsiveness Caused by GitHub Copilot Extension

Fixing VS Code UI Unresponsiveness Caused by GitHub Copilot Extension
This article shows a simple solution to a problem that doesn’t seem to be adequately documented: VS Code UI lags, freezes, and delays caused by the GitHub Copilot extension. Problem: VS Code UI Becoming Slow Having worked on a Python project for a while, I noticed that VS Code’s UI was frequently freezing for seconds at a time. This was happening in various places of the UI: the editor itself but also in the GitHub Copilot Chat window. Copilot also seemed to be taking more and more time getting ready to answer, and the extension-host process would fully saturate one CPU core for long periods of time.
Applications

Latest Posts

Fast & Silent 5 Watt PC: Minimizing Idle Power Usage

Fast & Silent 5 Watt PC: Minimizing Idle Power Usage
This micro-series explains how to turn the Lenovo ThinkCentre M90t Gen 6 into a smart workstation that consumes only 5 Watts when idle but reaches top Cinebench scores while staying almost imperceptibly silent. In the first post, I showed how to silence the machine by replacing and adding to Lenovo’s CPU cooler. In this second post, I’m listing the exact configuration that achieves the lofty goal of combining minimal idle power consumption with top Cinebench scores.
Hardware

Fast & Silent 5 Watt PC: Lenovo ThinkCentre M90t Modding

Fast & Silent 5 Watt PC: Lenovo ThinkCentre M90t Modding
This micro-series explains how to turn the Lenovo ThinkCentre M90t Gen 6 into a smart workstation that consumes only 5 Watts when idle but reaches top Cinebench scores while staying almost imperceptibly silent. In this first post, I’m showing how to silence the machine by replacing and adding to Lenovo’s CPU cooler. In a second post, I’m listing the exact configuration that achieves the lofty goal of combining minimal idle power consumption with top Cinebench scores.
Hardware