Minor upgrade is failing

336 Views Asked by At

I'm performing a minor upgrade but it's not updating files to one of my feature of an installer. It's giving following error in MSI log.

MSI (c) (88:64) [21:35:44:834]: Note: 1: 2262 2: Patch 3: -2147287038
MSI (c) (88:64) [21:35:44:834]: Machine policy value 'EnforceUpgradeComponentRules' is 0
MSI (c) (88:64) [21:35:44:834]: SELMGR: ComponentId '{A48DDBD3-3B28-F2FF-DBCE-0462EC330D7E}' is registered to feature 'Client', but is not present in the Component table. Removal of components from a feature is not supported!
MSI (c) (88:64) [21:35:44:834]: SELMGR: Removal of a component from a feature is not supported

I'm not deleting any component while making an upgrade installer. I have also checked for any component violation rules, but I didn't. I don't know why this happening. And because of that, feature 'Client' is going in Advertise state. I have also checked this component is not present in my MSI.

1

There are 1 best solutions below

0
On BEST ANSWER

Dynamic file/dependency scanning really isn't compatible with minor upgrades for this reason. Minor upgrades are very picky about their rules. If you really want to keep the dynamic consider switching to Major Upgardes. Either way, if you stick with minor upgrades always test your installers using the MSIENFORCEUPGRADECOMPONENTRULES=1 property setting.

As for your current situation, create a 0 byte file in your build environment of the same name and author it into the ISM exactly like you saw it in the build environment. Say component primary key, file primary key, component ID (guid) same feature ... everything. Now mark the component as transitive (I think it's called reevaluate in InstallShield.. sorry it's been awhile ) and give it a conditional expression that will always evaluate to false such as GoAway=1.

Now you'll pass minor upgrades rules and the component will be "punctured" and go away.

But I hope you can see this is only a patch. This situation can easily happen again using your current strategy. I highly suggest changing that.

Here's an article I wrote about 10 years ago that applies here:

http://blog.iswix.com/2007/06/dealing-with-very-large-number-of-files.html