Relevance check to make sure other action is not running

Hello All,

I have two install Fixletts.

  1. is an upgrade (remove old install new)
  2. is a plain install

'1. looks to make sure the machine is member of an AD group and that the older software exists (installed)
'2. looks to make sure the machine is member of an AD group and that the software does not exist (not installed)

But it is looking that fixlett 1 is taking time to completed and leaving a gap between removal and install.
Which causes Fixlett 2 to see that there is no software installed and then start its processing and clashing.

Is there a relevance check I can add into 2 to see if Fixlett 1 is currently running ?

I can see the Fixlett ID in the console, but have no idea how I would code a relevance check for this.
Or can the check be coded for the Fixlets name ?

All and any help appreciated.

you can simply combine Install & upgrade in one task using below relevance.

not exists service "XYZ" whose (version of it >= "1.0")

Or

you can create baseline with -

  1. to remove
  2. to Install/upgrade

Thanks for the information.
We do not have any service involved in the software.

We are also in rollout stage for fixlett 1. So i wish that there was a simple relevance check for a running fixlett. Is this not possible at all ?

I think I am going to try this

“exists names whose(it starts with “msiexec”) of processes”

To check in the relevance if the msi is actually running at the time.

Once the client has started to run the action it will not run a second one in parallel.

Baseline actions may interleave member actions, but there will only be one running action at any time.

Your plain install fixlet may become relevant while the upgrade fixlet is mid-stream, but if the upgrade action has not ended (either success or fail) the action will not start.

3 Likes

I would approach this as 1 fixlet that caters for either install or uninstall old version, install new version using relevance substitution in the actionscript.

Using the logic you would have for your existing fixlets, along the line of what @vk.khurava suggested, have the relevance so it applies if not exists application whose (version of it >= version you are deploying). You would need to figure out the best way of detection the existance of the app you are dealing with.

(windows of operating system) and (not exists regapp "FoxitReader.exe" whose (version of it >= "10.1.1.37576"))

In the action, using relevance substitution, check for the older version of the application and if true then waithidden the uninstall command.Then execute the application install command. Using an old version of Foxit reader as a example you can adapt for your use case

prefetch FoxitReader1011_enu_Setup.msi sha1:223d0e29b01e7b2f0816b0a4b929a4ae585b7d60 size:158801920 http://yourfile.resource.url/FoxIt/10.1.1.37576/FoxitReader1011_enu_Setup.msi sha256:94987e003e9fe07cb1051117cc0b389baca620e2c4a94ca37711c9933467a13f

if{exists regapp "FoxitReader.exe" whose (version of it < "10.1.1.37576") and (key whose ((value "DisplayName" of it as string as lowercase contains "foxit" as lowercase) and (value "Publisher" of it as string as lowercase contains "foxit" as lowercase) and (value "uninstallstring" of it as string as lowercase contains "msiexec.exe")) of key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall" of registry)}
	waithidden msiexec.exe /X {name of key whose ((value "DisplayName" of it as string as lowercase contains "foxit" as lowercase) and (value "Publisher" of it as string as lowercase contains "foxit" as lowercase) and (value "uninstallstring" of it as string as lowercase contains "msiexec.exe")) of key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall" of registry} /qn
endif

waithidden msiexec.exe /i __Download\FoxitReader1011_enu_Setup.msi /qn /norestart
2 Likes

Thanks everyone.
I will look to put the upgrade and install into one fixlett.

I would have the first fixlet set a reg key when it is done and make the second fixlet relevant only if the key is set.
Put them in a baseline and deploy it.

Interestingly enough, msiexec.exe /X {GUID} /qn will work even if the software is not installed, so you could skip the “if” part.

2 Likes