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

we have hundreds of databases on one sql server instance. After restart sql server takes databases online one by one using default order from sys.databases view. This order use database_id, so first created database in sql server startups first(as I think).. It takes about on minute to bring online all databases.

I had one high priority database which I want to be started up as soon as possible, but unfortunately this database has database_id>1000 (so now it came online in the end of the list.

How can I fix this: change database_id for example, specify priority, inject script which bring online this database first...?

Or the only way is to replace some database with low id with this high priority database(backup->restore..)?


share|improve this question

migrated from May 9 '11 at 18:49

This question came from our site for professional and enthusiast programmers.

What version of SQL Server are you on? – Martin Smith May 5 '11 at 13:53
sql server 2008 – lulhuh May 5 '11 at 16:13
Ah I thought SQL Server 2008 had multiple threads doing database recovery precisely because of this issue. Although not sure how many of these there are. – Martin Smith May 5 '11 at 16:14

There isn't a way to control the start up order of the databases in any supported manner, so far as I a aware. Do you have the option of installing another instance of SQL Server on that server and migrating the database to it? That would ensure that on system restart it would be started up immediately.

share|improve this answer

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.