• Resolved isradlt

    (@isradlt)


    Hello,

    We are using Pro version of the W3 Total Cache plugin and just found this post which states that is possible to use different endpoints for a database cluster.
    I have copied dbcluster-config-sample.php file into /wp-content/db-cluster-config.php and removed the comment for the following lines (line 154):

    $w3tc_dbcluster_config = array(
    ‘databases’ => array(
    ‘master’ => array(
    ‘host’ => DB_HOST,
    ‘user’ => DB_USER,
    ‘password’ => DB_PASSWORD,
    ‘name’ => DB_NAME
    ),
    ‘slave’ => array(
    ‘host’ => READER_HOST,
    ‘user’ => DB_USER,
    ‘password’ => DB_PASSWORD,
    ‘name’ => DB_NAME,
    ‘write’ => false,
    ‘read’ => true,
    ‘timeout’ => 0.2,
    )

    I have also declared ‘READER_HOST’ in my wp-config.php config file as follows:

    define(‘READER_HOST’, ‘mysql-cluster.eu-west-1.rds.amazonaws.com’ );

    Now I’m trying to find the button you mentioned in your post but I’m not able to find the ‘Enable database cluster’ button on the General Settings -> Database Cache page. What am I missing?

    We are using the latest 2.3.2 version of the plugin for a WordPress single site, not multisite/network.

    Thank you in advance 🙂

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘MySQL database cluster (write and read endpoints)’ is closed to new replies.