cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
slalande50
Level 5

Problem with Service install on VISTA

We have a product that we want to install on VISTA. In our InstallShield project, we install a service and start it during install procedure.

Before when the install was only for XP, we were using the ServiceControl Table and ServiceInstall Table and there were no problem. Now that we want support VISTA, the problem with our service is that we are dependant on VS2008 redistributable which are Merge Module that we have included in InstallShield. So after reading on several thread, I have decided to move the RemoveExistingProduct action after the InstallFinalize action. I also created custom action for starting, stopping and removing the service. Afterward we have deleted the service entry from the ServiceControl Table.

All was going well until we tried a major upgrade of the product. It seems that the RemoveExistingProduct action is deleting the service.

so my question is the following, Is it suppose to stop and remove the service during the RemoveExistingProducts if the service is in the ServiceInstall table.

Another point is that I also tried to add back the service to the serviceControl Table in order to specify NO to all of the Sart, Stop, Delete. But indeed, the Service was still deleted during the RemoveExistingProduct action.

Please someone Help since I've been on this case for about 1 week and still no clue.
Labels (1)
0 Kudos
(12) Replies
thepeter
Level 7

did you check to see if the executable used as the service still exists in that location? my guess is that the file is removed during uninstall and the service is removed with it as well.
0 Kudos
slalande50
Level 5

Well in my project, I did set the component, which contains the service, to Permanent. So I wouldn't expect it to be removed on an upgrade.
0 Kudos
slalande50
Level 5

Ok I just verified and I am positive that the executable files which is my service is not deleted.

Plus I added a custom action just between InstallFinalize and RemoveExistingProducts and I pop up a message box in my custom action just to know where we are in the procedure. And right after my custom action is executed, the service is stopped and deleted which should be the RemoveExistingProducts action.

Someone help please.
0 Kudos
thepeter
Level 7

what kind of upgrade type did you choose in "Major Upgrade Settings"? To make sure that the component is permanent and that the file is not removed, just uninstall the application. I would suggest you check the log file of the upgrade and see the state of the component. WiLogUtl.exe displays this information in a really "easy to read" way.
0 Kudos
Christopher_Pai
Level 16

Easy, get rid of the VS2008 Merge Module and use a Setup Prerequisite instead *OR* statically link the VS2008 libraries into your service EXE. Eitherway, get rid of the merge module.
0 Kudos
slalande50
Level 5

Thanks Christopher for youre response.

I don't want to use a prerequesite since there is the prerequisite dialog opening at the beginning of the installation. We cannot add more dialog than there is right now. Because we have done a temporary load that install the VS2008 redistributable in a prerequisite but it will not be accepted further because of the way it is being installed. My last option would be to install this VS2008 redistributable from a Custom Action right after the MoveFiles action will have occur. But I have not tried this at all. I wouldn't be suprise to get another misbehavior which I am getting alot since the beginning of VISTA.

How come Installshield does not support this anymore. It is like if you are using a service that depends on VS2008 merge module that will be installed on VISTA, then it seems that you are screwed. Shouldn't there be more support.

ThePeter, concerning the component, It is really set to permanent. And yes when uninstalling the product, all files are kept in the directory. About the WiLogUtl.exe, I have never heard about this executable. I will try to look at this file to see if it can help me in either way.

Another question I had is, if I use the new InstallShield 2009. Will the VS2008 redistributable be automatically included and will we need to include them as a merge module.

Thanks
0 Kudos
Not applicable

You're encountering limitations related to the deployment of the Visual C++ Merge Module and not limitations related to InstallShield. You can see more discussion on the topic of deploying these merge modules, as well as some issues others have run in to, here:
http://blogs.msdn.com/vcblog/archive/2007/10/12/how-to-redistribute-the-visual-c-libraries-with-your-application.aspx

Otherwise, the behavior of the merge modules is not with InstallShield's control. We did not write them and cannot really do much more than provide our feedback to Microsoft. As such, the way that the merge modules act between any versions is not going to substantially change (only how we might assist you in deploying them might).

My last option would be to install this VS2008 redistributable from a Custom Action right after the MoveFiles action will have occur. But I have not tried this at all. I wouldn't be suprise to get another misbehavior which I am getting alot since the beginning of VISTA


This won't work:
http://support.microsoft.com/kb/236456

You can also suppress the prerequisite dialog by passing /s to the Setup.exe (this won't suppress your MSI dialogs, though) if that's an option for you.
0 Kudos
slalande50
Level 5

Thanks BryanWolf for your response. It really clarified a lot of things.

As what I have read from the thread you gave, adding the Merge Module which I have tried since the beginning. But indeed, I have not been able to completely have a installer that will install those Merge Module, have my service that depend on the merge module run during the installation and finally do an upgrade without uninstalling the Merge Module and still have my service running.

I am almost there, because up to now, I have my service running without any problem after my installation but when I do an upgrade, I see my service deleted. Is this because of the RemoveExistingProducts action that I have scheduled after the InstallFinalize?

I really can`t find any thing on the web. Could someone list the different reason a service would delete itself on a major upgrade?

thanks
0 Kudos
Not applicable

RemoveExistingProducts performs an uninstallation of the product prior to reinstalling by default.

You could try resequencing the RemoveExistingProducts action by going to the Media -> Upgrades -> Upgrade Windows Installer Setup and then changing the setting for Major Upgrade from its current value to the "Install Setup then remove unneeded files" option.
0 Kudos
Christopher_Pai
Level 16

I still reccomend statically linking those dependencies into your service to do an end run around the ugly situation.

Another good read also is.... ( From Colby, IS Community member HookEm )

http://blog.deploymentengineering.com/2008/05/more-problems-with-ms-vc-8-sp1-merge.html
0 Kudos
Christopher_Pai
Level 16

Personally I disagree with the expert opinion given below. I suggest solving the problem by statically linking ( if possible .. see CLR notes ) and simply keep an eye out for updated runtimes, regression test and deploy when needed.

From http://blogs.msdn.com/vcblog/archive/2007/10/12/how-to-redistribute-the-visual-c-libraries-with-your-application.aspx

In addition to all the methods described above of distributing the Visual C++ libraries DLLs, there is one last option for building your application which does not require you to distribute the DLLs. However, this option only works for native-only code (it is not supported with /clr) and leaves your customers seriously vulnerable to any security holes as well as adds a significant burden upon yourself to patch all customer systems should a vulnerability be found in any of the libraries. This option is to statically link in the libraries as .lib files instead of dynamically loading them as DLLs. You do this by using the /MT flag on the cl.exe command line (vs /MD), or selecting the appropriate option in your project properties through Visual Studio. You may wish to use this option when testing early debug builds of your application on test machines before you start working on setup. [See footnote 3]
0 Kudos
slalande50
Level 5

I have no doubt that this would be working perfectly, by compiling VS 2008 redistributable statically, but having to deploy another release just because window has a hotfix does not make sense.

Just think about if you have 1000 clients that has a bug because of a window issue. And suddenly Window fixes there issue and now we have to deploy to all our customer a new release. This just doesn't make sense.

Is this issue fixed in installshield 2009 or it would be the same thing?
0 Kudos