Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Installing the service only if it is not present in the target mac
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  10 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Amar  
View profile  
 More options Sep 19, 6:06 am
Newsgroups: microsoft.public.platformsdk.msi
From: Amar <A...@discussions.microsoft.com>
Date: Fri, 18 Sep 2009 13:06:14 -0700
Local: Sat, Sep 19 2009 6:06 am
Subject: Installing the service only if it is not present in the target mac
Hi all,

Phil, as you suggested i have written the information in both the tables
Service Control and Service Install. It works fine.

Now my question is i had to copy some files for installing the service in
the target manchine. So i want to avoid this when i do the installation
second time, or adding a patch, When i install second time, my msi file
should check if service is already installed in the machine, if yes, it
should not copy the files and also it should not install the service.

One thing i want to do is i want to remove the values what i have entered in
service control table because service get uninstalled when my new patch or
version in installed.

If i do this directly from the Custom Action UI and using the property NOT
PREVIOUSVERSIONSINSTALLED  it did not work

Please suggest.

Regards,
Amar.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Wilson, Phil  
View profile  
 More options Sep 23, 10:31 am
Newsgroups: microsoft.public.platformsdk.msi
From: "Wilson, Phil" <ph...@wonderware.nospam.com>
Date: Tue, 22 Sep 2009 17:31:18 -0700
Local: Wed, Sep 23 2009 10:31 am
Subject: Re: Installing the service only if it is not present in the target mac
There are some complications here.

1) You can't install the same setup a second time, so you're talking about
some kind of upgrade. If it's a major upgrade, then that's an uninstall and
an install, so generally speaking you do want to uninstall the service.

2) For a patch you can condition the way you're installing the service with
a condition such as NOT PATCH.  So the InstallServices and DeleteServices
standard actions can be conditioned on NOT PATCH if you're using the
ServiceInstall/Control tables.

3) You're referring to PREVIOUSVERSIONSINSTALLED, so that probably means
you're doing a major upgrade, so a patching scenario won't apply.

Generally speaking, if you're using the ServiceControl and ServiceInstall
tables to install services then you don't need Visual Studio custom actions
or any conditions at all, and RemovePreviousVersions should just work.

--
Phil Wilson
The Definitive Guide to Windows Installer
http://www.apress.com/book/view/1590592972

"Amar" <A...@discussions.microsoft.com> wrote in message

news:5F80DE31-1B75-4B3E-8404-575F9A3D7D65@microsoft.com...


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Installing the service only if it is not present in the target" by Amar
Amar  
View profile  
 More options Sep 23, 11:19 am
Newsgroups: microsoft.public.platformsdk.msi
From: Amar <A...@discussions.microsoft.com>
Date: Tue, 22 Sep 2009 18:19:01 -0700
Local: Wed, Sep 23 2009 11:19 am
Subject: Re: Installing the service only if it is not present in the target
Hi Phil,

Thank you for your reply.

2 point )

For a patch you can condition the way you're installing the service with
a condition such as NOT PATCH.  So the InstallServices and DeleteServices
standard actions can be conditioned on NOT PATCH if you're using the
ServiceInstall/Control tables

I would prefer this answer. But here you are saying it applies only for a
patch. In my case there is no concept of patches. I mean here when we are
chaning to a new version there would be some few set of files which are
changed.

In my case when the user installs for the first time also it should check
whether the service is already installed ( Because this is a third party
service which would have already been installed by the user and he might have
done some changes to the configuration also, So i dont want to copy the files
again ( files which are related to service, I can do this keeping a condition
in Launch Conditions or makiing it is permanent) and also i dont want to
install the service again). How to check this condition in the Service
Install table?
And this process follows for every install.

Thanks for you help and suggestions. It is quite useful for all the
developers.

REgards,
Amarnath Aitha.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Wilson, Phil  
View profile  
 More options Sep 29, 3:42 am
Newsgroups: microsoft.public.platformsdk.msi
From: "Wilson, Phil" <ph...@wonderware.nospam.com>
Date: Mon, 28 Sep 2009 10:42:18 -0700
Local: Tues, Sep 29 2009 3:42 am
Subject: Re: Installing the service only if it is not present in the target
I only mentioned patching because you used the word in your original post.

It doesn't seem to me that there is anything much here that MSI can do for
you. Basically you need a custom action to check if a service is already
installed or not (or maybe a registry search for the service entry). Then
you need a condition on the service executable and on the service install
that they won't get get installed if the service already exists.

I don't know you got to the point where you are (or might be) installing a
3rd party service. If they allow you to redistribute and install that
service also, then they should supply a merge module that you (and everyone
else) can use to install the service if necessary, and do the right thing
with configuration etc.
--
Phil Wilson
The Definitive Guide to Windows Installer
http://www.apress.com/book/view/1590592972

"Amar" <A...@discussions.microsoft.com> wrote in message

news:F448CE1B-01D3-40BA-B2C0-62BCCC81E142@microsoft.com...


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Amar  
View profile  
 More options Sep 29, 5:52 am
Newsgroups: microsoft.public.platformsdk.msi
From: Amar <A...@discussions.microsoft.com>
Date: Mon, 28 Sep 2009 12:52:02 -0700
Local: Tues, Sep 29 2009 5:52 am
Subject: Re: Installing the service only if it is not present in the target
Hi Phil,

Thank you for your reply.

"Then

> you need a condition on the service executable and on the service install
> that they won't get get installed if the service already exists."

I would search the registry for the name and will keep a condition on
service executable. How to keep the condition in the service install table.
What is the attribute which should be updated to check this condition in the
following

ServiceInstall,Name,DisplayName,ServiceType,StartType,ErrorControl,LoadOrde rGroup,Dependencies,StartName,Password,Arguments,Component_,Description
which are the column names for service install table.

I am installing the service using service install table and service control
table. So Please let me know how to keep this condition here.

Amar.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Wilson, Phil  
View profile  
 More options Oct 1, 6:35 am
Newsgroups: microsoft.public.platformsdk.msi
From: "Wilson, Phil" <ph...@wonderware.nospam.com>
Date: Wed, 30 Sep 2009 13:35:46 -0700
Local: Thurs, Oct 1 2009 6:35 am
Subject: Re: Installing the service only if it is not present in the target
Add your condition to the InstallServices standard action, if this is the
only service you're installing.
--
Phil Wilson
The Definitive Guide to Windows Installer
http://www.apress.com/book/view/1590592972

"Amar" <A...@discussions.microsoft.com> wrote in message

news:640D4D1C-E608-45C8-A733-587964AFBA11@microsoft.com...


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Amar  
View profile  
 More options Oct 2, 9:13 am
Newsgroups: microsoft.public.platformsdk.msi
From: Amar <A...@discussions.microsoft.com>
Date: Thu, 1 Oct 2009 16:13:01 -0700
Local: Fri, Oct 2 2009 9:13 am
Subject: Re: Installing the service only if it is not present in the target
Hi Phil,

Thank you for your response.

So what i understand from below is

In the InstallExecuteSequence table value for InstallServices should be
updated with the CONDITION "NOT INSTALLED"

InstallServices NOT Installed   5800

How to do this writing a query, for inserting the row i am using the query
to write from the C++ code.

"INSERT INTO
`ServiceControl`(`ServiceControl`,`Name`,`Event`,`Arguments`,`Wait`,`Compon ent_`)
VALUES ('NR Service
Control','NR',162,'',0,'C__8E79904005DE45829AB2CC2750DE30C0')"

If i want to update the values for InstallServices how should i write the
query?
InstallServices    VersionNT      5800 should be replaced with
InstallServices NOT Installed   5800

thanks,
Amar


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Amar  
View profile  
 More options Oct 8, 6:44 am
Newsgroups: microsoft.public.platformsdk.msi
From: Amar <A...@discussions.microsoft.com>
Date: Wed, 7 Oct 2009 13:44:01 -0700
Local: Thurs, Oct 8 2009 6:44 am
Subject: Re: Installing the service only if it is not present in the target
Hi Phil,

I am able to successfully update the table value NOT Installed from the code.

But still i see when i run the installer, it is overriding the existing
service. Though i have ketp a condtion that it should be installed
only if the service is not installed "NOT Installed"

Please let me know if i am missing something.

Thanks in advance,
Amar


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Wilson, Phil  
View profile  
 More options Oct 9, 10:23 am
Newsgroups: microsoft.public.platformsdk.msi
From: "Wilson, Phil" <ph...@wonderware.nospam.com>
Date: Thu, 8 Oct 2009 17:23:53 -0700
Local: Fri, Oct 9 2009 10:23 am
Subject: Re: Installing the service only if it is not present in the target
Exactly what is your condition and where is it?

--
Phil Wilson
The Definitive Guide to Windows Installer
http://www.apress.com/book/view/1590592972

"Amar" <A...@discussions.microsoft.com> wrote in message

news:760CC6C7-6B66-415A-88FE-17AFABBA02B4@microsoft.com...


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Amar  
View profile  
 More options Oct 10, 5:31 am
Newsgroups: microsoft.public.platformsdk.msi
From: Amar <A...@discussions.microsoft.com>
Date: Fri, 9 Oct 2009 12:31:01 -0700
Local: Sat, Oct 10 2009 5:31 am
Subject: Re: Installing the service only if it is not present in the target
Hi Phil,

I am updating the value installservices in InstallExecuteSequence.

Action             Condition         Sequence
InstallServices 'NOT Installed' 5800

This is all what i have done

1) I have filled the ServiceInstall and ServiceControl tables.
2) edited the installservices value with NOT Installed Condition.

I want to achieve this functionality

1) My msi installer would have to copy the service related files and install
the service only when the service is not previously installed
by any other person or program.
2) When i install i should not replace the existing files of the service if
it is already installed. ( we dont know, at runtime we should check
whether this service is already installed by some on the target machine
already.) This is because the user might have changed the information in the
config files. So we dont wnt to touch the config files or any service related
files.
3) If we write table values for Service Control table, while uninstalling it
is removing all the service related files, It should not remove any service
related files
while un installing.

Regards,
Amarnath Aitha.

...

read more »


    Reply    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google