Patching

  • Thread starter Thread starter Mark Kerns
  • Start date Start date
M

Mark Kerns

I'm using MSI 2.0 on Win2000 and need feedback on how to undo a patch. I
know there's no native way to do it but I'd like to improvise as follows
(alternatives welcome). I want to send my customers two ".msp" files for
each patch, one to patch the main app itself and another ".msp" to undo
(downgrade) that patch if later required (a patch of a patch basically).
Instead of the overhead of two ".msp" files however, making a download of
both files twice as expensive, I want to send the main ".msp" file itself
and create the undo ".msp" at the client site (I'll automate the process,
creating the undo ".msp" file just before running the main ".msp" file). The
question is, how exactly do I create the "undo.msp" file at the client site?
I'll ship the following:

1) Main ".msp" patch file
2) ".pcp" file to create the undo ".msp" file
3) ".msi" file corresponding to the undo ".msp" file that will be created
4) "msimsp.exe" and "Patchwiz.dll" from MS (can I legally ship this BTW)?

I can then run "msimsp.exe" in 4 above just before installing the main patch
(passing the ".pcp" file in 2 above). To do this however, I know that two
tables in the ".pcp" file must point to the appropriate ".msi" files but
where do I locate the *target* ".msi" file on the client site (or do I need
to ship this too). Can someone shed some light on the precise technical
details to pull this off if possible (the latter question in particular
since I think I have most of the details now). BTW, I'm an experienced C++
developer so feel free to get technical. Thanks.
 
I won't feel comfortable doing something like this. In essense the msp is
nothing but the difference between two MSIs, and you just don't have them
available in the form that you need. You will end up copying source files
and msi so that the files can be located. More over the license agreement
might not let you redistribute those MS files.
--

Regards,
Sajan.

PS: Please don't send me direct emails, use the newsroom.
 
I won't feel comfortable doing something like this. In essense the msp is
nothing but the difference between two MSIs, and you just don't have them
available in the form that you need. You will end up copying source files
and msi so that the files can be located. More over the license agreement
might not let you redistribute those MS files.

Thanks for the feedback. Actually, it appears that it will work as I believe
I've nailed down the final details (extensive testing to follow however).
Whether I can distribute MS's files is another story though. More to the
point though, I fail to understand:

1) Why MS didn't provide a native undo feature in the first place. What
happens if the patch has a problem for instance (the app fails to start
afterwards). Some critical systems like the one I'm working on will need to
undo that patch immediately and resume with the old (unpatched) app. Note
that there's no guarantee an undo feature will be available in 3.0 either
though it has been officially discussed (and though I did research a manul
undo of the patch, the patching registry entries are undocumented for
instance, so I can't manually undo them even though I established how - they
may change in a future release).

2) Their whole patching process is problematic anyway. As you already
(indirectly) pointed out, each ".msp" file targets a specific version to
patch so your customers must apply each patch successively (they can't skip
any). If someone downloads patch 1.0.4 of your app for instance, you need to
manually ensure that patches 1.0.1 through 1.0.3 have been applied first. So
how do you enforce this without automating the process yourself? (a
complicated, manual process). A cumulative system of applying patches is
therefore required.

Anyway, thanks again for you help.
 
This is definitely being addressed in MSI 3.0. It will include support for
patch removal, multiple patching, and other patch related features. In fact,
MSI 3.0 seems to be totally focussed on fixing the current weaknesses in the
patching process. Of course, only time will tell how well it addresses these
problems ;-)

David
 
This is definitely being addressed in MSI 3.0. It will include support for
patch removal, multiple patching, and other patch related features. In fact,
MSI 3.0 seems to be totally focussed on fixing the current weaknesses in the
patching process. Of course, only time will tell how well it addresses these
problems ;-)

Let's hope so. These are serious weaknessess and I fail to understand how MS
could release MSI with such gaping and obvious deficiencies (and I'm
normally a staunch MS supporter). Thanks for you comment.
 
Back
Top