WordPress.org

Ready to get started?Download WordPress

Forums

hyperdb: can't load wordpress page from read-only instance (1 post)

  1. j-ray
    Member
    Posted 3 years ago #

    Topology: wordpress mu 2.9.1.1 installed on two separate hosts.
    master(hostA)->slave(hostB) replicated "blog" database
    hyperdb (mainly for r/w splitting)

    I configure "hostA" for read/write with write priority:
    read => 2
    write => 1

    I configure "hostB" as read-only:
    read => 1
    write => 0

    Then, to test, I take down the mysql database on "hostA" - and navigate to my blog URL.

    I get this error:
    Unable to connect to hostA:3306 to write table "wp_1_term_relationships" (global)

    This seems odd, because I don't believe I'm trying to write anything - just read the page. The mysql log file indicates that only select statements are being passed to the server - so I don't see any insert/update/delete activity there either.

    If I configure them both for write - it works fine. However, I am trying to provide users at the "hostB" location with at least read access to the blog if the master node (hostA) is down or the network is unavailable.

    Please advise.
    Thanks,
    Joe

Topic Closed

This topic has been closed to new replies.

About this Topic