473,763 Members | 9,161 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

windows service - installutil.exe

when i run my program, an error message prompt me that i should add the
installutil.exe . How do i checked for the installutil.exe ? How can i add
it to my Timer program?

----------------------------------------------
when you fear to fail, you fear something that
has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #1
7 34385
What you should actually add is an installer class for registering the
service within the system. I believe MSDN has pretty detailed documentation
on how to deploy Windows services with custom actions (namely, installer
classes launched by the Windows Installer) so you should start from getting
acquainted with this info. I might sound not very friendly, but this is not
because I don't want to help you, it's just MSDN writers explained the
things much better than I'd do.

--
Sincerely,
Dmitriy Lapshin [C# / .NET MVP]
Bring the power of unit testing to the VS .NET IDE today!
http://www.x-unity.net/teststudio.aspx

"scarred wind" <sc*********@ya hoo.com> wrote in message
news:uz******** ******@TK2MSFTN GP09.phx.gbl...
when i run my program, an error message prompt me that i should add the
installutil.exe . How do i checked for the installutil.exe ? How can i add
it to my Timer program?

----------------------------------------------
when you fear to fail, you fear something that
has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


Nov 16 '05 #2
i'll check it out soon. thanks!

----------------------------------------------------------
when you fear to fail, you fear something that has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #3
You can manually install the service - it's pretty easy.

If you have the VS.NET command prompt, just type installutill <service>,
where <service> is the complete path to the executable file in your bin
directory. This will install the service for you, where you can control it
from the services manager under Administrative tools in your control panel.
To uninstall the service, just type installutil -u <service>.

If you do not have a VS.NET command prompt, it's no big deal, you just have
to specify the full path for the installutil program, which is I think by
default under <your windows dir>\Microsoft. Net\framework\< framework version
dir\installutil .exe.

I hope this helps!

"scarred wind" <sc*********@ya hoo.com> wrote in message
news:uz******** ******@TK2MSFTN GP09.phx.gbl...
when i run my program, an error message prompt me that i should add the
installutil.exe . How do i checked for the installutil.exe ? How can i add
it to my Timer program?

----------------------------------------------
when you fear to fail, you fear something that
has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 16 '05 #4
Thank you very much to those who have helped me.

My Error Prompt:

Window Service Start Failure:
Cannot start service from the command line or debugger. A Windows
Service must first be installed (using installutil.exe ) and then started
with the ServerExplorer, Windows Service Administrative tool or the NET
START command.

I still can't figure it out, I hope you can be patient with me, I'm
quite new to C#. I thank you very much for helping me get around this
thing.

----------------------------------------------------------
when you fear to fail, you fear something that has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #5
Services are a little bit different from regular executables. In order to
run a service, it first need to be registered within the system, as it will
be started not by launching the .exe file, but by means of Service Control
Manager - a part of Windows managing all services. There's a kind of
protocol (namely, a sequence of SCM calls to your service) being executed
when a service starts.

To register the service with SCM, you need to add an installer class for the
service. To the best of my knowledge, there is a prepackaged installer class
in the framework designed just to register services within the system (and
this is documented in MSDN). This installer class will be invoked by the
installutil.exe utility to perform the registration. Now, that the service
is known to the Service Control Manager, it can be started by the ways
described in the error message you are getting.

--
Sincerely,
Dmitriy Lapshin [C# / .NET MVP]
Bring the power of unit testing to the VS .NET IDE today!
http://www.x-unity.net/teststudio.aspx

"scarred wind" <sc*********@ya hoo.com> wrote in message
news:%2******** *******@TK2MSFT NGP12.phx.gbl.. .
Thank you very much to those who have helped me.

My Error Prompt:

Window Service Start Failure:
Cannot start service from the command line or debugger. A Windows
Service must first be installed (using installutil.exe ) and then started
with the ServerExplorer, Windows Service Administrative tool or the NET
START command.

I still can't figure it out, I hope you can be patient with me, I'm
quite new to C#. I thank you very much for helping me get around this
thing.

----------------------------------------------------------
when you fear to fail, you fear something that has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


Nov 16 '05 #6
thank you again to all of you...

would it be possible for any of you to give me sample code, so that i
can refer to it?

thanks again.

----------------------------------------------------------
when you fear to fail, you fear something that has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #7
thank you all, very very much! i think i've solved the that error now.
But my installation is unsuccessful, and a Rollback is performed. What
could have caused it to install unsuccessfully?

Thank you,

-----------------------------------------------------------
when you fear to fail, you fear something that has not yet happened.

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
6002
by: Vlad | last post by:
Is there any way to install multiple instances of the same windows service designed with VS.NET 2003? I tried copying the binaries into a separate folder and then copying registry entries for the original service under a new name but the SCM complains that the executable does not have this service implemented. Please note that I need to have distinct instances of executables installed not merely multiple windows services defined within...
7
3685
by: sidd | last post by:
Hi All, i have some doubts on .net windows services.. please see if some one could help me understand this.. 1)is it possible to install a windows service which does not have a installer added to it, using installutil.exe OR is it must to have an installer to the service project to be able to
2
21912
by: Mark | last post by:
I created an extremely simple windows service that only writes to the EventLogs on Stop and Pause. I installed it using the InstallUtil.exe program, the output of which is below. It appears to be successful. I'm now ready to start my service (I think) but the NET START command does not appear to indicate that the service is available to be run. The output for NET START is below as well. The Services list in the W2K administrator...
5
26537
by: Jacobus Terhorst | last post by:
I created a simple windows service. However when I built it again a couple of days later I could no longer install the service. The InstallUtil.exe cannot UNINSTALL the service because "The specified service does not exist as an installed service" However InstallUtil.exe cannot INSTALL the service because "The specified service already exists." Are there some registry entries I have to remove?
7
7946
by: Larry Bird | last post by:
I have a windows service that want to un-install. When I run "installutil /u serivcename" I get the error that the serivce is not installed on my machine. However, when view the serivce console I still see my service there. What must be done to remove a windows service written in VB.Net from my system. I'm trying un-install the service because I'm compiling it as a console application to perform debugging. I think it will be easier to...
4
2930
by: SQLScott | last post by:
My esteemed VB.Net gurus, I posted this question a week or so ago and recieved 1 response that helped me somewhat but really did not solve the problem (but I do appreciate the response). I have spent countless hours searching everything I can think of but I cannot solve this problem, so I post again with hopes that someone knows something that will put me on the right track.
4
4182
by: tshad | last post by:
What would be a good way to check programmatically whether a service was running? We have a service that dies periodically and I need to check to see if this service is running. I know how to check to see if the status is in stopped or running mode. But that doesn't tell me if it is actually running. I need to know this so that if it happens I can programmatically start the same service on another machine.
5
5177
by: S Moran | last post by:
following this tutorial http://www.c-sharpcorner.com/UploadFile/mahesh/window_service11262005045007AM/window_service.aspx installutil seems to complete successfully, but the service is not listed in services, and trying NET START servicename returns "the service name is invalid" im running on vista... any ideas?
5
3307
by: dm3281 | last post by:
I'm really starting to hate writing services -- or trying to, anyway. Why do I need to rename my project to the service name? Why do I need to set the "ServiceName" property to my service name? Why do I need to set a property within my code to the service name? Are all these required or am I just doing this for consistency purposes?
0
9387
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10148
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10002
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8822
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5270
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5406
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3917
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3528
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2794
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.