Title: HyperDB with separate databases
Last modified: August 20, 2016

---

# HyperDB with separate databases

 *  [chanchua2007](https://wordpress.org/support/users/chanchua2007/)
 * (@chanchua2007)
 * [14 years, 2 months ago](https://wordpress.org/support/topic/hyperdb-with-separate-databases/)
 * Hello,
 * I’m stuck with this, please help me :
 * I have a Multiste with 500 blogs as subdomains. It’s been slowing down and the
   number of tables in this is about 15000+ .
 * I decided to separate this database into 10 databases and moveving the tables
   from the original databases accordingly. Then I used HyperDB for this model.
 * It seams OK when I create new site and it create new tables in different databases.
   But the problem is when I open a blog, it can not find the right databases and
   cause “Error database connection”. With some press of F5 button, it show the 
   correct blog but back to error again.
 * Anyone had faced this issue ? Please help me to solve it.
 * I have config like this in the db-config.php file :
 * `
    $wpdb->add_database(array( 'host' => 'xxx.127', 'user' => 'wordpress', 'password'
   => 'wordpress', 'name' => 'wordpress_host3', 'dataset' => 'global', 'write' =
   > 1, 'read' => 0, ));
 * $wpdb->add_database(array(
    'host' => 'xxx.127', 'user' => 'wordpress', 'password'
   => 'wordpress', 'name' => 'wordpress_blog003', 'dataset' => 'blog', 'write' =
   > 1, 'read' => 0, ));

The topic ‘HyperDB with separate databases’ is closed to new replies.

## Tags

 * [multi database](https://wordpress.org/support/topic-tag/multi-database/)

 * In: [Networking WordPress](https://wordpress.org/support/forum/multisite/)
 * 0 replies
 * 1 participant
 * Last reply from: [chanchua2007](https://wordpress.org/support/users/chanchua2007/)
 * Last activity: [14 years, 2 months ago](https://wordpress.org/support/topic/hyperdb-with-separate-databases/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
