Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Windows Server 2003 MySQL 5.x

Hi Guys,

I have a service that requires mysql to be running when starting up. I'd like ensure that mysql itself starts well before other windows services during reboots. Is there a way I can easily set this up?

Ideally, I'd like some way within windows to establish start up order or implement a delay mechanism for other third-party services. I've seen other methods implement a sleep timer for the services but I'm not too comfortable with this...

Any suggestions?

share|improve this question
up vote 6 down vote accepted

In Windows 2003, service dependency order is your only mechanism for changing the order that Service Control Manager starts services w/o writing code.

You should identify the specific services that you want to start after MySQL and add depedency entries such that MySQL is started first. (Whether or not you can actually get what you want will depend on exactly which services you're trying to start MySQL before.)

share|improve this answer
Yup, sounds good, and when you think about it, it's probably the way things should be. Can you imagine the support calls - "I changed the startup order and now my machine is broken" - eeewww. That aside, if service A depends on service B then the depencency stuff seems the best place to control the order. – Le Comte du Merde-fou Nov 12 '09 at 23:59

Not easily like Unix allows us to do, but you have make a service dependant on another service, and it wont start till after that service starts. If you want the service to start right at the bottom of the queue, make it dependant on the login service or the DHCP service if you have it installed. Netlogon is one of the last to start because of the need for so many other services and will ensure your process starts very late into the boot cycle.

share|improve this answer
I initially upvoted this--Microsoft's own lit agrees with you--but today I realized that this approach means that if you need to restart, say, the DHCP service, it downs whatever services you have made dependent on it that actually aren't. – Kev Aug 17 '10 at 12:25

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.