I'm still looking for a solution, or at least some guidance, even though I agree that it goes beyond the usual good practices. - jJack 1 hour ago
I do not have access to my deployment tools, but I will try to present a perspective. Since I do not fully understand all aspects of what you write, there will be general comments. Hope this is at least related to what you are asking. He turned into a blog, as I wrote.
For me, the MSI patch is effective for 2 main scenarios :
- You fix the error in the uninstallation sequence of the installed product with a small update patch.
- You are delivering a small patch for several files as a “ patch ” for the released product, which can be huge and time-consuming to reinstall.
For these two purposes, I have used MSI fixes effectively professionally several times. In each case, there was no other good fix. The IMHO fix for a “fix” is what the whole technology is for, and not for deploying frequent, incremental updates. . Providing updates for 96 files is NOT ./p>
A patch is an update to work . Remember that a patch is just a more compact delivery mechanism for an update that already works. This can be a major, minor, or even minor update, and each will work differently. Before doing anything else, make sure you check the actual full MSI update before attempting to pack it as a patch. This is the best advice I can give you. All efforts spent on the correction are lost if the full update does not work correctly. And yes, this includes installing, uninstalling and updating in all interactions before making the patch itself. These are perhaps the most common bug fixes for everyone.
There are several barriers to removing a patch . There are dozens of technical issues that can lead to the removal of fixes (recommended reading). This is a huge problem from time to time because the patch that deployed the patch can be found defective and therefore must be completely discarded. In my opinion, this is one of the main uses of the small patch - deploy a quick fix, which can then be thrown back.
Patch conditions and user actions : for me, one of the worst aspects of the fix is ​​that user actions in packages may not be properly processed so as NOT to be triggered when a patch operation is performed, rather than a normal installation. A patch has patch properties such as PATCH and MSIPATCHREMOVE . Use these conditions for custom actions so that they start or do not start during the patch, depending on what you need. Be careful with the conditions of user actions, they are difficult to get right. The following is the " MSI Conditions Barcode " to help you. I have not tested these conditions - testing is the only guarantee.
Some additional troubleshooting tips :
- I would forget the basic fixes for the update. I tried them and will try them again, but they are usually not perfect. Absolute requirement for the main fix for the update is that RemoveExistingProducts is placed after InstallFinalize in InstallExecuteSequence. The reason for this is that otherwise the files will be deleted before the fix pack attempts to fix the existing files. Enough to catch 22.
- a minor update does not remove the existing installation, but rater re-caches the new MSI file for use in maintenance and uninstall operations. This means that a patch can fix the removal sequence before it is launched - one of the best fixes that I mentioned above. In fact, if a minor update works, a fix may not be necessary at all. Just use a minor update if your MSI file is not very large and you want to provide a small “fix”.
- If you need to include files in your patch, I recommend including " include whole files ". Otherwise, a bit-level fix is ​​performed, and this is unnecessary complexity (unless your binaries are huge).
- Include only what you need in the patch. Do not add files or settings that are not required, and you can make a reliable patch. Avoid adding custom actions, if at all possible.
- As already mentioned: remember that a patch uses the same InstallExecuteSequence installation as a regular installation, but you can customize user actions differently using patch specific properties such as PATCH and MSIPATCHREMOVE . Use these conditions for custom actions so that they start or do not start during the patch, depending on what you need.
- The reference to the components must be 100% correct for any type of patch to work.
- Minor patch updates should be launched with the appropriate msiexec.exe command line to work if they are not supplied through the setup.exe / update.exe file.
- Third-party merge modules often lead to patch problems in my experience.
- Versions "as they call it - the black art of providing files is always updated by adding another version to the MSI file for the file on disk, it seems to cause fix errors.
- The patch will show the same graphical interface as the main installation. In my opinion, this is an erroneous design. User actions in the GUI can ruin the repair process.
- I believe that every patch should be cumulative - replacing all previous patches. I never got this working properly when I tested several patches installed sequentially and sequentially. For many reasons, I came to the conclusion that there was a useless approach to fixing it . I had problems exactly according to what you describe with patch families, target versions, etc. The patch is not too smart, it's just a complex package of several files trying to find the product to which it belongs.
The obvious thing is that I really do not recommend you go with this correction method, even when asked. However, I read this thread , which seems to indicate a successful fix for those who switched to using WIX instead of Installshield. You should also check out the CodeProject link.
As for your deployment scenario , I don’t fully understand all its aspects, but it seems like the developers want the patches to convert the direct application into the current version of QA through the patch? I would never agree with this, or the script should be different from how it sounds. The completely wasted effort to create the patch, when you should already perform small or large updates in the first place - they are more than enough to deliver software to ensure quality. You can use the dev branch to provide a separate MSI, and then create some patches and then check that the product is a patch, but I would never use patches to deliver the installers of your product from the inside. I do not know if you asked about this.
Work with small and large updates - it is advisable that the latter are not fixed, and deliver the patch when you really need it. If installation time is a problem, can you just schedule a major daily update after completing the nightly build on all development PCs and QAs? (including killing any running processes necessary for the installation to work). I don’t know if I will fully track what your scenario really is.
Check out Stefan Kruger installsite.org for additional updates and fixes.
Check out this famous wix tutorial for updates and fixes. And MSDN .