1

I am about to give deliver an upgrade to a product in the form of an MSI to an enterprise. I believe they deploy this to various workstations via GPO.

What is the likely sequence of events in performing an upgrade to a product in this setting?

Will they use GPO to uninstall the previous version of the product first and then deploy the new MSI?

Or will they expect the new MSI to automatically uninstall the previous version?

CJ7
  • 653
  • 10
  • 24

3 Answers3

8

What is the likely sequence of events in performing an upgrade to a product in this setting?

They will likely make a new publication and revoke the old one.

Will they use GPO to uninstall the previous version of the product first and then deploy the new MSI?

This is TOTALLY irrelevant for you. MSI that are properly coded WILL trigger at least the uninstall of a previous version.

Or will they expect the new MSI to automatically uninstall the previous version?

They will assume the MSI behaves like that because this is the behavior it should have.


Edit: Tiggering the uninstall of an old version is trivial in a new version:

https://stackoverflow.com/questions/114165/how-to-implement-wix-installer-upgrade

<Property Id="PREVIOUSVERSIONSINSTALLED" Secure="yes" />
<Upgrade Id="YOUR_GUID">  
   <UpgradeVersion
      Minimum="1.0.0.0" Maximum="99.0.0.0"
      Property="PREVIOUSVERSIONSINSTALLED"
      IncludeMinimum="yes" IncludeMaximum="no" />
</Upgrade>

So, the new build CAN triger the nuisntall without additional "coding". This is purely configuration.

TomTom
  • 51,649
  • 7
  • 54
  • 136
  • Would it be hard for them to uninstall all the old versions if I cannot provide an MSI that uninstalls the previous version? The uninstalling requires extra MSI coding which I haven't had time to do. – CJ7 Feb 22 '12 at 11:58
  • 3
    Ah - yes, it would. It requires them to remove the app / unpublish it, then wait for this to happen everywhere before rolling out the new version. This can take ages (laptops rearely connecting etc.). I strongly would consider you cleaning up. It is no that hard - if the MSI uninstalls, all yo nee to do is to make sure the next MSI uses the same product code and some other hings then it automatically triggers the uninstall. No coding in the new MSI is needed except the "major update" hooks. – TomTom Feb 22 '12 at 12:07
  • 1
    I edited the answer with the hooks. it is trivial. – TomTom Feb 22 '12 at 12:08
  • I think this enterprise does its own packaging. Is it possible they would sort out all this? Oh, and I use Installshield so that WiX stuff is useless to me! – CJ7 Feb 22 '12 at 12:12
  • 2
    if theyx do their own pacakaging, they are responsible for it. Still you should provide the uninstall hook. YOUR msi shoudl behave. I never looked at a specific custoemr when doing an installer - I always followed the rules laid out by MS, and in 10 years or so I never got a single problem with that. – TomTom Feb 22 '12 at 12:14
  • @CraigJ It's quite likely that they're re-packaging rather than packaging. They will expect you to provide a properly created MSI that will either uninstall or upgrade the previous version as part of its install. They may then deploy it along with an MST to send additional settings, etc, or may do something more drastic, but they will expect to start with a properly behaved MSI – GAThrawn Feb 22 '12 at 17:56
2

First thing: When you deliver the program to a single company, you could just ask your customer what he expects.

Generally though, the most important thing is to document the steps needed to upgrade your program. As an admin, I need to now if I can just deploy it and it will take care of things or if I need to undeploy the old version first (which I wouldn't like, but it's OK if I know that it's necessary).

Make this documentation for different methods of installation. GPO is very likely but not guaranteed to be used.

Lastly: Please go through your old questions and accept the answers you've got. Your low accept rate will people make think twice if it's worth their time answering you.

Sven
  • 98,649
  • 14
  • 180
  • 226
  • -1. There IS a standard. – TomTom Feb 22 '12 at 11:50
  • Yeah, great if your environment is following that standard and the app in question is of a kind that allows to follow that standard as well. Sadly, neither is guaranteed, so what I need the most as an admin is the documentation telling me what the app needs. – Sven Feb 22 '12 at 11:56
  • Can you use GPO do uninstall apps? Is it that easy? – CJ7 Feb 22 '12 at 12:00
  • Well, you can remove the puiblication and tell the GPO to uninstall. And yes, throw away programs made by people gthinking adhering to a standard is too mundane for those geniuses. – TomTom Feb 22 '12 at 12:05
  • 1
    In general, those people not ttriggering an unisntall of the old version generally have no idea how to build an installer. Check my answer for all the "code" that is needed to trigger the uninstall of another version from the new MSI. not doing that is laziness. Or incometence. – TomTom Feb 22 '12 at 12:10
  • @TomTom: I use Installshield so it's not as simple as that. – CJ7 Feb 22 '12 at 12:32
  • Crappy tools = crappy results. Nothing except WIX ever worked without problems for me, sadly. Thank heaven someone finally made somehing that supports MSI technolgoy in full and not in a "hidden" way. – TomTom Feb 22 '12 at 12:47
0

While it may be nice for a vendor to do this, it isn't practical to depend on it.

We usually check if the product is already installed, and if there is an existing uninstall key in the registry, and run that. If that does not fully uninstall the product, we have secondary procedures to remove the known folders and registry keys.

This may also need to include running something like the sc command to stop, disable, and delete services if applicable. Uninstallation may also require a restart before proceeding with the installation of a new version.

Greg Askew
  • 35,880
  • 5
  • 54
  • 82