SDutt
Posts: 20
Joined: Fri Oct 17, 2025 8:35 am

Service being started during product upgrade, even though corresponding feature has not been selected in dialog

Hello,

We're using Advanced Installer 23.9, per-machine MSI with EXE bootstrapper.

In our product install we have a custom feature selection dialog to let the user
select some features to be installed. There are a few checkboxes on this dialog,
and each of these corresponds to one property, which is set to true when that
particular feature is selected. On the Organization page, each optional feature
has "Not installed" as the default with an "Installed if" condition, for example
CHECKBOX_RL = "true".

This works fine on a direct installation. For one particular feature, say
Feature RL, there is a corresponding Windows service to be installed and
started, and even that works correctly when Feature RL is selected. Because this
feature is large, its payload is downloaded at install time, and the download is
conditioned on the same property.

The problem appears on upgrade. Version 3.1.0 is already installed, and we then
install 3.1.4 without uninstalling, leaving Feature RL unticked exactly as in the
working direct-install case. The feature gets selected anyway, so its service is
created and started, while the downloaded part of the feature is missing — those
downloads are conditioned on the property, which is correctly false. The service
cannot start, we get Error 1920, and since it is marked vital the whole upgrade
rolls back.

From the verbose log, CHECKBOX_RL is never set, so the feature condition is
correctly false, yet the feature is selected anyway:

15:39:59 MigrateFeatureStates: ... setting feature 'FeatureRL' to 'Absent'
15:40:06 PROPERTY CHANGE: Adding ADDLOCAL property. Its value is 'ALL'
15:40:09 UpdateFeaturesInstallStates ... Return value 1
15:40:09 Doing action: FeatureSelectionDlg
15:40:14 Feature: FeatureRL; Installed: Absent; Request: Local; Action: Local

Looks like MigrateFeatureStates runs only on upgrade.

Not sure what exactly is going wrong. Please let us know the reasons and a solution.

Thanks in advance,
SDutt
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Service being started during product upgrade, even though corresponding feature has not been selected in dialog

Hi SDutt,

I'm really sorry for the delayed reply. It seems we missed your post somehow.

The behavior you encounter is normal. Any feature that is installed with a version will always be installed during an upgrade. This happens because all features are migrated by default from a version to another.

If you want to prevent that, you can go in the "Upgrades" page of your project, check the "Customize Advanced Installer upgrade rules" option, double-click on the first rule and in the "Upgrade Actions" tab uncheck the "Enable Migrate Features action" option.

Let me know if this helped.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”