db-config.php 578 Bytes
Newer Older
lechuck's avatar
lechuck committed
1 2
<?php

3
// Common settings
Joe Oblivian's avatar
Joe Oblivian committed
4
$wpdb->persistent = true;
5 6
$wpdb->max_connections = 30;

7
define("NOBLOGS_BACKEND_CONFIG", "/etc/noblogs/backends");
8
define("NOBLOGS_MASTER_CONFIG", "/etc/noblogs/master");
9
define("NOBLOGS_HOST_FILE", "/etc/noblogs/ip_ring0");
lechuck's avatar
lechuck committed
10

11 12
include_once('r2db/db-hash.php');
include_once('r2db/db-backends.php');
lechuck's avatar
lechuck committed
13

14 15
// Set up global dataset with master databases
noblogs_load_global_dataset(NOBLOGS_MASTER_CONFIG, NOBLOGS_HOST_FILE);   
16 17

// Add all the sharded blog databases.
18
$wpdb_reverse_backend_map = noblogs_load_backends(NOBLOGS_BACKEND_CONFIG, $wpdb->hash_map);