/build/static/layout/Breadcrumb_cap_w.png

Uninstall MSI + "NOT Installed" property

One of the first MSI I wrote (4 years ago) includes a custom action, just starting an executable with certain parameters.
The installation of the MSI is o.k.
But I forgot to set the custiom action to "NOT Installed" so that during an uninstall this action is not executed.
And now, we are upgrading this software and the uninstall doesn't work. Why not? Because this executable is first removed during the uninstall and after that the custom action kicks in and can't find the executable the error message is something like "A part of the installation cannot be run....".

Is there a workaround to fix this problem?

I know its stupid not to test an uninstallation, but back in the days I was new to MSI technology.

0 Comments   [ + ] Show comments

Answers (6)

Posted by: turbokitty 17 years ago
6th Degree Black Belt
0
I would just deploy an MSP that fixes the condition first.
Posted by: spartacus 17 years ago
Black Belt
0
One idea might be to first create a modified version of the original MSI with the correct condition added to the Custom Action.

You could then reinstall the application forcing a recache of the MSI in preparation for the uninstall as follows :

msiexec /i <Name of modified MSI> REINSTALL=ALL REINSTALLMODE=vp

(add silent qualifiers such as /qb-! if needed)

The cached MSI will then hold the revised condition for your CA and you can then proceed with an uninstall using

msiexec /x <ProductCode of modified MSI>

(add silent qualifiers such as /qb-! if needed)

This method might not be that appropriate for larger packages because of the time taken to reinstall. Also, if the CA was added through a transform, then this will not work because the recache is only performed on the base MSI (I think)

Regards,

Spartacus
Posted by: subsense 17 years ago
Purple Belt
0
Thanks for these options, I think I will try the second option. the fualty CA is in a base MSI. I will write a script for the logon script. The installation is about 180 mb's maybe I consider the MSP option. Could be faster. I will search for the right parameters.
Posted by: peska 17 years ago
Senior Yellow Belt
0
Hi,


You could modify your original MSI and set the Custom Action to "NOT Installed"
Then run this command, before uninstalling or upgrading, to recache the MSI installation.
This command will recache the MSI without the need to reinstall it.
Then the Custom Action won't run when you upgrade/uninstall.

msiexec /fv <full-path to msi>


peska
Posted by: MSIMaker 17 years ago
2nd Degree Black Belt
0
How was the msi originally deployed? Did the user click on it and install it or was it done through AD or SMS?
Posted by: subsense 17 years ago
Purple Belt
0
Pesta,

Thats a bit how I solved the problem.

The original MSI was deployed using Deployment Center (VAI), a tool like SMS.
I fixed the original MSI, placed the MSI on a share.
During the logon proces I use de REINSTALL=ALL REINSTALLMODE=vp /qb switches.
The install kicks in an will last 20 seconds, the original MSI is about 80 mb's so the MSI doesn't reinstall fully.
But is does fix the problem!

A second scripts kills the w32mkde.exe proces + removes the logfiles + exe, so the MSI will nog hang on that.

Thanks all for your help, I certainly will try the /fv switch
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ