How to stop an existing service during installation?

8 messages Options
Embed this post
Permalink
Shane_Corbin

How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
 I'm new to WiX and have an installer that installs a set of PCI drivers.
An existing service uses these drivers and I need to stop it before
upgrading drivers, then restart it after the drivers have been installed
such that the service uses the new drivers.  The service has a seperate
installer and needs not be included in my driver package installer.  What
is the most appropriate way to do this?  If I can stop the service during
the installation then a reboot isn't required, and that would be
preferred.  I've tried creating custom actions that run a "net stop
<service>" and "net start <service>", but haven't got the syntax for that
figured out.  It seems there has got to be a better way.

Thanks!
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users
Blair-2

Re: How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
You should be able to use the ServiceControl table (which you can author
using the ServiceControl element in WiX).

-----Original Message-----
From: [hidden email] [mailto:[hidden email]]
Sent: Monday, November 02, 2009 9:48 AM
To: [hidden email]
Subject: [WiX-users] How to stop an existing service during installation?

 I'm new to WiX and have an installer that installs a set of PCI drivers.
An existing service uses these drivers and I need to stop it before
upgrading drivers, then restart it after the drivers have been installed
such that the service uses the new drivers.  The service has a seperate
installer and needs not be included in my driver package installer.  What
is the most appropriate way to do this?  If I can stop the service during
the installation then a reboot isn't required, and that would be
preferred.  I've tried creating custom actions that run a "net stop
<service>" and "net start <service>", but haven't got the syntax for that
figured out.  It seems there has got to be a better way.

Thanks!
----------------------------------------------------------------------------
--
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users
Shane_Corbin

Re: How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
I tried using the ServiceControl table but it looks like it's used to
specify that you would like <service> to start/stop when the the installer
begins an install/uninstall.  That's not what I'm trying to do.  I want to
sequentially stop a service, run my installer to completion, then start
the service back up.
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users
Blair-2

Re: How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
If you select "both" for Stop and for Start, it will stop the service before
changing any of your files/registry/etc. during both installation and
removal and start it again after making those changes. Isn't that what you
are describing you want to do?

-----Original Message-----
From: [hidden email] [mailto:[hidden email]]
Sent: Monday, November 02, 2009 1:56 PM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] How to stop an existing service during
installation?

I tried using the ServiceControl table but it looks like it's used to
specify that you would like <service> to start/stop when the the installer
begins an install/uninstall.  That's not what I'm trying to do.  I want to
sequentially stop a service, run my installer to completion, then start
the service back up.
----------------------------------------------------------------------------
--
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users
Shane_Corbin

Re: How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
That seems to work fine for installation, but can I force the service to
stop on uninstall?
Thanks again!
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users
Blair-2

Re: How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
Works the same way. That is why you say "both" instead of "install".

The stop happens before any files are erased or registry keys/values are
removed, or any other related activities.

-----Original Message-----
From: [hidden email] [mailto:[hidden email]]
Sent: Monday, November 02, 2009 4:05 PM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] How to stop an existing service during
installation?

That seems to work fine for installation, but can I force the service to
stop on uninstall?
Thanks again!
----------------------------------------------------------------------------
--
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users
Shane_Corbin

Re: How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
Perhaps I'm misunderstanding.  On install I'd like to stop the service, do
the installation and then start the service.  On uninstall I'd like to
stop the service, and uninstall without starting the service back up at
the end of uninstallation.
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users
Blair-2

Re: How to stop an existing service during installation?

Reply Threaded More More options
Print post
Permalink
I thought the service used the drivers, but existed before the drivers were
installed (which would suggest that they would be started again upon
uninstallation of the drivers).

Change Start to "install", leave Stop as "both".

-----Original Message-----
From: [hidden email] [mailto:[hidden email]]
Sent: Monday, November 02, 2009 4:35 PM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] How to stop an existing service during
installation?

Perhaps I'm misunderstanding.  On install I'd like to stop the service, do
the installation and then start the service.  On uninstall I'd like to
stop the service, and uninstall without starting the service back up at
the end of uninstallation.
----------------------------------------------------------------------------
--
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
WiX-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wix-users