Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

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

I have 5000 databases on one server.

Switching databases is taking a long time sometimes 2 seconds. (use databaseA)

IT is showing up in a my slow queries log. Is there any way to make this go faster.. some form indexing or some other configuration?

share|improve this question

Short of beefing up your server hardware, you could start splitting off databases to several servers, as 5000 databases on a single server is pretty huge.

Something that will cut your I/O wait, which is most likely an issue is an SSD, but a good one costs hundreds of $.

share|improve this answer
5000 databases doesn't seem like alot to me considering the databases themselves are all pretty small bar a few of them. it doesn't make sense to me that it would take 2 seconds to traverse 5000 databases when it could traverse 5000 rows in a fraction of the time.. – Derek Organ Oct 28 '09 at 15:26

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.