Home All Groups Group Topic Archive Search About

Windows Service using VB.Net automatic startup problem !

Author
25 May 2006 5:37 PM
Ravi Shankar
Hello,

I have written a service using VB.Net which is basically a asynch socket
listener. I have been able to install it successfully. Using the Service
Control Manager I am able to start & stop the service successfully. Once
started, the service is responding to requests. The service runs under a user
a/c (the user is part of the local administrators group).

I have set the ServiceDependsOn to TCP/IP Protocol Driver, Event Log, Remote
Procedure Call (RPC) and AD Network Support Services (something like that).

after all this when I boot the system the service does NOT start and in the
event log I get a "Service did not respond in a timely fashion" message.

Suggestions ? (if I'm in the wrong place then please tell me which NG should
this go to)
--
Ravi Shankar

Author
25 May 2006 6:21 PM
Charlie Brown
I don't know if this will help you or if it applies to you, but I have
the same problem when I have event logging in my service as well.
Author
26 May 2006 1:56 PM
Ravi Shankar
Hi Charlie Brown,

Your observation got me thinking and from the Service Design Sheet I deleted
the EventLog component. I then changed the code of my service to start using
me.EventLog to write to the error log.

NET RESULT - The service started (without any errors) when I rebooted the
system. Just to make sure I rebooted & rebooted and it still worked :)))
--
Ravi Shankar


Show quoteHide quote
"Charlie Brown" wrote:

> I don't know if this will help you or if it applies to you, but I have
> the same problem when I have event logging in my service as well.
>
>
Author
26 May 2006 9:16 AM
Kevin Yu [MSFT]
Hi Ravi,

Are you starting the service automatically or manually? If it fails on boot
up, can you try to start the service manually?

Kevin Yu
Microsoft Online Community Support

============================================================================
==========================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
============================================================================
==========================

(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Author
26 May 2006 1:45 PM
Ravi Shankar
Hi Kevin,

From the Service Control Manager I could start the service manually without
any problems.

However, I did one thing today and it has started working. Following
"Charlie Browns" comment I removed the "Event Log" from the Service Design
sheet. Instead I started using the Me.EventLog for logging events and the
service started up just fine... god knows why but I've decided to leave it at
that :)
--
Ravi Shankar


Show quoteHide quote
"Kevin Yu [MSFT]" wrote:

> Hi Ravi,
>
> Are you starting the service automatically or manually? If it fails on boot
> up, can you try to start the service manually?
>
> Kevin Yu
> Microsoft Online Community Support
>
> ============================================================================
> ==========================
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> ============================================================================
> ==========================
>
> (This posting is provided "AS IS", with no warranties, and confers no
> rights.)
>
>
Author
29 May 2006 5:10 AM
Kevin Yu [MSFT]
It was nice to hear that you have had the problem resolved.

Thanks for sharing your experience with all the people here. If you have
any questions, please feel free to post them in the community.

Kevin Yu
Microsoft Online Community Support

============================================================================
==========================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
============================================================================
==========================

(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Author
30 May 2006 2:53 PM
Charlie Brown
I will have to try that workaround myself.  Glad to know it helped.