Disabling self repair
I am faced with a strange problem. My client is requesting that I disable the self repair option from some of our MSI packages. First option I thought of is to set all Key paths blank but I’m not sure yet as to what impact it might have on my package. Removing the Advertise shortcut might do the trick but then again I’m not sure if it is sufficient to prevent any self repair. Any suggestion or a list of what conditions could trigger the self repair would help.
0 Comments
[ + ] Show comments
Answers (5)
Please log in to answer
Posted by:
MSIMaker
20 years ago
Well.....if the reason is because you are delivering user data files that will change......then remove the component ID from the table so that self repair doesnt overwrite them.
If it is because the files you are delivering will be changed by the user or updated by a later version then remove the component ID so that they wont be uninstalled by a newer version.
If you will need to remove the whole app and replace it with a new version but dont want to overwriite the files already installed then you have to do 2 things.
Deploy it without a component ID
Then deploy the3 new app and select "dont overwrite if keypath exists" on the new version.
That about covers it.
If it is because the files you are delivering will be changed by the user or updated by a later version then remove the component ID so that they wont be uninstalled by a newer version.
If you will need to remove the whole app and replace it with a new version but dont want to overwriite the files already installed then you have to do 2 things.
Deploy it without a component ID
Then deploy the3 new app and select "dont overwrite if keypath exists" on the new version.
That about covers it.
Posted by:
yvonne
19 years ago
I do not want to trigger self repair on some components because my customer my change or remove files but I want the files to be removed if the MSI-package is uninstalled. Is that possible?
MSIMaker, I notice that you did not comment on Sartos suggestion to leave key path with no value (<none>). I seems to be a solution, but it is not nice to have a red component, is something wrong? When I read the Windows Installer Help it says "If the value is not NULL, then KeyPath is either a primary key into the Registry, ODBCDataSource, or File tables depending upon the Attribute value. If KeyPath is null, then the folder of the Directory_ column is used as the key path."
MSIMaker, I notice that you did not comment on Sartos suggestion to leave key path with no value (<none>). I seems to be a solution, but it is not nice to have a red component, is something wrong? When I read the Windows Installer Help it says "If the value is not NULL, then KeyPath is either a primary key into the Registry, ODBCDataSource, or File tables depending upon the Attribute value. If KeyPath is null, then the folder of the Directory_ column is used as the key path."
Posted by:
MSIMaker
19 years ago
Posted by:
yvonne
19 years ago
Thank you. I suppose empty key paths are not a good way to go. So now I have removed the component ids to prevent self repair. I have also created new components for each folder to remove all files in the folders during ininstall so it seems that I have solved my problem.
I just wonder, is it possible to add a component that removes all folders, subfolders and files in a tree. My customer may create new folders and want then removed as well if he unistall. I do not know how to get rid of them.
I just wonder, is it possible to add a component that removes all folders, subfolders and files in a tree. My customer may create new folders and want then removed as well if he unistall. I do not know how to get rid of them.
Posted by:
kkaminsk
19 years ago
I know of a site where they can't have MSIs repair due to a bug with ZENWorks and locked down user environments. What they do is remove all the Windows Installer specific keys for the MSI after the MSI has been installed. So you have a MSI perform the installation but then throw Windows Installer away after the initial install. You loose the ability to have the MSI uninstall but then again it wont be able to repair itself either.
MSIZAP might be a better option than to try an find all the registry entries for a MSI.
MSIZAP might be a better option than to try an find all the registry entries for a MSI.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.