Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

REINSTALLMODE emus with Feature Conditions


3 replies to this topic

deramor

deramor
  • Full Members
  • 187 posts

Posted 15 September 2016 - 19:46

Hello all,

 

I am trying to provide some repair functionality with a software package.

 

I am executing my installer (which is a single exe release) with the following command line: /V"/qb! REINSTALL=ALL REINSTALLMODE=emus /norestart"

 

After running this command, I see a feature get installed that I don't want to be installed.

This feature has an InstallLevel of 101 by default.  It is set to 1 if the following condition is true: FLAG<>0 OR REMOVE="ALL".  Where "FLAG" is a property that needs to be passed on the command line.

 

My issue is that the repair command is installing a feature with a condition on it that I intended to be false in this scenario.  I'm at a loss as to what I am doing wrong.  I made a log of this process and noticed the feature had an entry: MSI (s) (48:14) [14:08:40:645]: Feature: visasysM; Installed: Local;   Request: Reinstall;   Action: Reinstall

 

Does anyone have thoughts on this?

 

Edit: Using different logging verbosity, I was able to find MSI (s) (D4:8C) [14:48:30:939]: PROPERTY CHANGE: Adding REMOVE property. Its value is 'ALL'.

 

So I should amend my previous question to be, What about my command line arguments is setting the REMOVE property to ALL?  Obviously this is making my condition true.


Edited by deramor, 15 September 2016 - 19:51.


Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 16 September 2016 - 07:01

Is this the only entry for the REMOVE property in the log? Which action is preceding it?

This: Feature: visasysM; Installed: Local; looks like the problem might already happen in the first install. Did you generate a log for it, too?

What is the value of INSTALLLEVEL? Does visasysM have any child features?

The InstallValidate action may change the REMOVE property, but it's scheduled after CostFinalize, which is the action that evaluates the Condition table.

Note that in Basic UI mode (/qb) the InstallUI sequence is skipped.

Just a shot in the dark: does the problem also happen if you set REINSTALLMODE=omus ?



deramor

deramor
  • Full Members
  • 187 posts

Posted 18 October 2016 - 19:18

Thanks for your questions.  My work priorities were changed and I had to drop this project for some time. 

When I returned, I thought about it more.  My initial approach was flawed.  I instead used Feature states and actions in my condition.

 

I set a flag with the conditions:

&Feature1=2 AND !Feature1=3

 

In other words:

If Feature1 action was InstallState_Absent AND Feature1 state is InstallState_Local then I would set a flag.

 

In testing, this would mean if the feature was previously installed and now is removed, set a flag.

I do not have to handle the opposite scenario (feature not installed now is).

 

I ended up removing the REMOVE property from the situation since I had some trouble with it and this seemed like a more direct approach.

 

Also Stephan, your answer here (https://community.fl...on-in-Basic-MSI) helped me to understand the difference between state and action.  It is always better to understand why something works.

 

Thanks again.



Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 24 October 2016 - 17:46

I'm glad you found a solution