? Setting Service Timeout

A

Alec S.

Hi,

This is the closest newsgroup I could find for what I need.

I am looking for a way to specify the timeout for an NT service. Specifically, there are a couple of services that sometimes hang
on startup (COM+ Event System, Task Scheduler) and this causes a massively long bootup (5+ minutes). Worse still, it seems to be
doing this more and more often now. Since I have been unable to identify the cause (especially since it's intermittent), I have
resigned myself to at least alleviate the symptom.

I want to set the timeout to a smaller value so that if they do hang, I don't have to wait forever to get control of my system.
Even if they were critical to the functioning of my system (they are not), I'd rather get control right away so that I can reboot
and try again instead of waiting five minutes to try again.

I've looked everywhere and while I can find the occasional mention of the existence of service timeout values, I can't find any
mention on how to set them.

Can anyone please tell me how I can do this? It's really driving me crazy.


Thanks a lot.
 
W

Wesley Vogel

WaitToKillServiceTimeout
http://www.microsoft.com/resources/documentation/Windows/2000/server/reskit/en-us/regentry/26734.asp

Why not just disable both COM+ Event System & Task Scheduler?

I have them both disabled.

However, Task Scheduler service is needed if you use Prefetch.

This is the only downside that I see to having COM+ Event System service
disabled....
Note if disabling this service then at every boot there will be generated a
warning in the Event Log about this service not running.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
D

ducky

I don't have to wait forever to get control of my system.

Are you talking about before you get to the welcome/login screen when
booting? you can disable them thru the services snap-in of the
computer management console. alternatively, you can use a batch file
or scripting to shell the 'net stop' command to turn them off
programatically (this would have to be done once you are in windows
tho)

HTH

AR
 
P

Pop`

Alec said:
Hi,

This is the closest newsgroup I could find for what I need.

I am looking for a way to specify the timeout for an NT service.
Specifically, there are a couple of services that sometimes hang on
startup (COM+ Event System, Task Scheduler) and this causes a
massively long bootup (5+ minutes). Worse still, it seems to be
doing this more and more often now. Since I have been unable to
identify the cause (especially since it's intermittent), I have
resigned myself to at least alleviate the symptom.

I want to set the timeout to a smaller value so that if they do hang,
I don't have to wait forever to get control of my system. Even if
they were critical to the functioning of my system (they are not),
I'd rather get control right away so that I can reboot and try again
instead of waiting five minutes to try again.

I've looked everywhere and while I can find the occasional mention of
the existence of service timeout values, I can't find any mention on
how to set them.

Can anyone please tell me how I can do this? It's really driving me
crazy.


Thanks a lot.

Personal opinion of course, and you're entitled to your own opinion:

Although I understand your frustration I think if it were me I would opt to
fix it somehow. Even if what you propose can be done, it's only
hiding/covering a problem that exists somewhere and may manifest itself in
other ways eventually. I had a very similar problem in fact, and never was
able to fix it until I finally bit the bullet, did a final backup, and
reinstalled everything from scratch.
My first effort was to reinstall from an image but the problem had been
there for a long time so next I reinstalled the OS and only used the image
for non-OS data. It workled; now Event Viewer is still nearly empty every
time I check it and completely devoid of any errors or warnings.

HTH
Pop`
 
A

Alec S.

Pop` said:
Although I understand your frustration I think if it were me I would opt to
fix it somehow. Even if what you propose can be done, it's only
hiding/covering a problem that exists somewhere and may manifest itself in
other ways eventually. I had a very similar problem in fact, and never was
able to fix it until I finally bit the bullet, did a final backup, and
reinstalled everything from scratch.
My first effort was to reinstall from an image but the problem had been
there for a long time so next I reinstalled the OS and only used the image
for non-OS data. It workled; now Event Viewer is still nearly empty every
time I check it and completely devoid of any errors or warnings.


Actually I have not had to reinstall Windows for almost four years because I have a wonderful system that I devised based on drive
imaging. Whenever my system bogs down from WinRot™, I just restore it from the latest image (I have more than a dozen for the OS
alone). Unfortunately even that will only work for so long, eventually newer images which include updates will start becoming less
and less stable. That's what's happened here. I could restore an older image from before this started happening, but then it would
not have all the latest patches and such.

I've already tried looking for the cause and came up empty. I searched far and wide, I've run test after test, and diagnosed until
I was blue in the face, but could not find a reason for it. There just isn't enough information given as to why it's happening or
what's causing it.

I am already planning to wipe everything (replaceable) and start over, but at this point it's going to be such a massive undertaking
(countless pieces of software and more setting and configurations than there are atoms in the universe, let alone all the testing to
make sure it's all good) that I am trying to put it off for now. I intend to wait until either I end up moving to Vista which would
require starting over anyway, or until I can get updates to all my software. Either way, I am band-aiding until then.

Yes, I could disable them but even if I didn't have an urgent reason to do this, I still want to know how to set NT service
timeouts. I have read that MySQL uses a timeout of 24 hours but could not find where that is stored. I would really like to find
out how to do this anyway.
 
K

Ken Blake

Alec said:
Actually I have not had to reinstall Windows for almost four years
because I have a wonderful system that I devised based on drive
imaging.


I have never reinstalled Windows--XP or any other version (and I've run
almost all of them since Windows 3.0, each from the time it was released
until the next version). And I've never needed to restore everything from
an image, either.

With a little bit of care, anyone can do the same. The thought that Windows
needs periodic reinstallation is simply wrong.
 
A

Alec S.

Ken Blake said:
I have never reinstalled Windows--XP or any other version (and I've run
almost all of them since Windows 3.0, each from the time it was released
until the next version). And I've never needed to restore everything from
an image, either.

With a little bit of care, anyone can do the same. The thought that Windows
needs periodic reinstallation is simply wrong.


I'm sure there are plenty of people who don't need to reinstall Windows. There are also a lot of people who use only three programs
their whole lives. People who test software, develop software, or pretty much anything besides just browsing the Internet, email,
and viewing pictures of the grandkids, will eventually have reason to clean house, whether that means reinstalling or not.



Anyway, back to the point, I would like to know how to set service timeouts for use in my own NT services.
 
K

Ken Blake

Alec said:
I'm sure there are plenty of people who don't need to reinstall
Windows. There are also a lot of people who use only three programs
their whole lives. People who test software, develop software, or
pretty much anything besides just browsing the Internet, email, and
viewing pictures of the grandkids, will eventually have reason to
clean house, whether that means reinstalling or not.



I'm far from from one of those three-programs people. And I've never needed
to clean "house," either.

And I know lots of other people, also nowhere near three-programs people,
who have never needed to reinstall or do any dramatic housecleaning.
 
W

Wesley Vogel

It took me less than ten minutes on Google to find this.

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\ServiceName\Parameters

Right click in the right hand pane | Point to New | Click DWORD Value and
add...

Value Name: WaitHintStart
Data Type: REG_DWORD
Value: <Time to wait for service to start in milliseconds>

To estimate what numbers should be entered for the Value, Microsoft
recommends that you perform the following steps:

1. Start the service, and then time how long it takes to start.
2. Modify the numbers according to the amount of time that you think it will
take to start. Over estimate the time, because if the service ever takes
longer to start, then any of the other dependants services will not start.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
A

Alec S.

I'm far from from one of those three-programs people. And I've never needed
to clean "house," either.

And I know lots of other people, also nowhere near three-programs people,
who have never needed to reinstall or do any dramatic housecleaning.


Well then, care to share your secret? Why keep your "little bit of care" a secret?
 
A

Alec S.

Wesley Vogel said:
It took me less than ten minutes on Google to find this.

It took you less than 10 minutes on Google to find one of only 30 (3 unique) pages in the whole Internet? Damn, that's pretty good,
no it's down right miraculous; nice job.

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\ServiceName\Parameters
Value Name: WaitHintStart

But, the rest of that page says:

"A supported fix is now available from Microsoft, but it is only intended to correct the problem that is described in this
article. Apply it only to computers that are experiencing this specific problem. This fix may receive additional testing. Therefore,
if you are not severely affected by this problem, Microsoft recommends that you wait for the next Windows NT service pack that
contains this hotfix."

It seems to be a hack, and one that only the IISAdmin uses at that. I'll try it anyway but it looks like there may not be a way to
do this:

"When the service starts, the Service Control Manager is notified that you are going to start in xx seconds or less. This time is
hard-coded in the IISAdmin service to 10,000 milliseconds, which is not enough time if the metabase is too large."

I just checked the sources for MySQL and can confirm that the timeout is embedded as part of the program. It seems timeouts are
hardcoded and there is no method to override it. If this is indeed the case, then it is very odd since pretty much everything else
is adjustable.

Worst case scenario, I'll have to find the location of the embedded timeout in svchost.exe and patch it. :| There must be a way to
override it, there are ways to override several other timeout settings…
 
K

Ken Blake

Alec said:
Well then, care to share your secret? Why keep your "little bit of
care" a secret?



Nothing at all special or mysterious. Mostly just staying away from dodgy
web sites, not downloading pirate software, running a firewall, and keeping
up to date with my anti-virus and anti-spyware programs. Anyone can do the
same.
 
A

Alec S.

Ken Blake said:
Nothing at all special or mysterious. Mostly just staying away from dodgy
web sites, not downloading pirate software, running a firewall, and keeping
up to date with my anti-virus and anti-spyware programs. Anyone can do the
same.


Sorry to tell you that's not true, not anyone can do that. Not everyone can afford a multitude of security software and "dodgy"
websites and pirate software are FAR from the only cause of problems. It sounds like you really are one of those people who use a
limited set of programs day in and day out. You are not a software developer are you? You don't sound like you do any kind of
testing or diagnostics either. Either that or you have some kind of miracle system. Plenty of smart people (computer experts even)
who don't use pirate software or frequent "dodgy websites", and who run security software still have problems and require a clean
out every now and then. Your "advice" is more accusatorial then helpful. Worse still, you did not even come close to addressing
the question posed, you only blurted out an absolutely useless boast about yourself without even offering a tip (as incredibly off
topic as it would have been) on how to avoid having to reinstall.

Like your post, Wesley's reply sounded a little arrogant and was not too useful either, but at least he addressed the question in
addition to boasting.

A cursory scan through this newsgroup reveals that the few replies you make are arrogant and self-aggrandizing, and worse, the same
old useless tripe over and over. When someone asked about a way to avoid reinstalling Windows, besides telling them the exact same
thing you told me (which had nothing whatsoever to do with what I asked) you advised them that removing malware is better than
reinstalling. Are you crazy or just ignorant? It may be more convenient but better? Never! Removing malware will AT BEST leave
the system in whatever state it was before it was removed but that is almost never the case. By the time you get to removing
malware, it has already done it's damage and even after it is removed, traces are almost always left. A fresh install is like
buying a brand new car instead of just taking the near-death old one in for a tune-up. No matter what, a fresh new car will be
cleaner and healthier than an old, decrepit car that is repaired. There is only so much a tune-up can do. I don't know how you
became an MSMVP (I suppose it could be an old moniker that has long since expired), but based on what I've seen, you certainly don't
seem to deserve it.

Honestly, your posts give the impression that you are a teenager or younger. No wonder Microsoft stopped allowing people under 18
to be MVPs (yes, yes, and for the safety of minors as well.)
 
K

Ken Blake

Alec said:
Honestly, your posts give the impression that you are a teenager or
younger. No wonder Microsoft stopped allowing people under 18 to be
MVPs (yes, yes, and for the safety of minors as well.)


You want to start a fight. Find someone else to fight with. I'm not
interested in defending myself against your ad hominem attacks, I'm not
interested in flame wars,and I'm not playing your games. You are welcome to
your views on me or anything else.

Goodbye.
 
A

Alec S.

Ken Blake said:
You want to start a fight. Find someone else to fight with. I'm not
interested in defending myself against your ad hominem attacks, I'm not
interested in flame wars,and I'm not playing your games. You are welcome to
your views on me or anything else.

Goodbye.


Big term for a kid. I guess you missed the facts I presented?

Goodbye.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top