• Hi folks,

    We have a WordPress install with a master-slave mysql config here, and thought it’d be a good idea to explore HyperDB. As with most WP sites, we’re way heavier on reads than writes and this could really help distribute our load.

    What I want to do is send all writes to the master, and split the reads evenly between the master and slave. The problem is that all the queries are apparently going to the master. I know the HyperDB code is running, because I commented out the database credentials from the normal place in wp-config.php. But still, the slave is getting practically no work to do.

    My configuration in db-settings.php is:
    add_db_server(‘global’, 0, ‘mydc’, 1, 1, “dbmaster”, “dbmaster”, “dbname”, “dbuser”, “dbpass”);
    add_db_server(‘global’, 0, ‘mydc’, 1, 0, “dbslave”, “dbslave”, dbname”, dbuser”, “dbpass”);

    Obviously the documentation on this thing is a bit sparse, but I think this configuration describes what I want to do. Any pointers would be greatly appreciated!

    Regards,
    Martin

  • The topic ‘HyperDB — is this thing on?’ is closed to new replies.