Hi,
I have some slow embedded PC's running Windows 2000 and am having trouble starting a service reliably. There is a VERY noticeable delay between issuing the command 'net start xxx' and the message 'the xxx service is starting'. This is causing my service to fail to start.
My service regularly fails to even receive a 'Start' command (I am logging this and can see that it never occurs).
I tried to repeat this on a much faster XP box, but the delay is of course MUCH shorter. I did however deliberately add a sleep(60000) in my Onstart handler - to simulate a slow startup.
On this (XP) box - even though the net start command returns 'the xxx service could not be started (after about 20+ seconds), the service seems to continue on and does indeed start. During this time service manager reports 'starting' - until my sleep(60000) completes and service manager reports started.
I ALSO tried setting the 'ServicesPipeTimeout' registry entry to 65000 - and this seems to have made no difference whatsoever :-O - yes I did a reboot ;-).
Does anyone have any idea why this happens please ??. Even though I have set up my 'ServicesPipeTimeout' registry entry to 65000 - the net start fails after 20 or so seconds :-O.
It would appear that IF I manage to get a start command issued before this 'net start' command times out - my service will indeed start up. This is why I tried setting the 'ServicesPipeTimeout' registry entry to 65000 - but it seems to make no difference at all.
NB My service app is written in C# using VS2008 targetted at .Net Framework V2 - as thats all that the old 2000 boxes can support.
Many thanks - ever hopefully....
Regards
Graham