Multi-DB config for replication (master/slave)

Elite
  • 11 points
    Starting to get into this DEV thing
    I'm new here
    hiptobesmart

    Member  —  11th December 2010 (1 year ago)         

    I have one web server which will be connecting to two database servers set up with 256 databases in a master/slave configuration. I have installed wordpress, set up my network, placed the multi-db files in their proper location and the configuration seems to be lost on me, which is embarrassing due to the fact that I am a web developer and intermediate server admin.

    Both servers are on the same network (same data center). Here are my questions:

    1. Do I simply duplicate the add_db_server calls for the slave server with different host information and the write flag set to 0?

    2. Can I get a clear definition of the HOST and LAN_HOST arguments in the add_db_server function? The values in the sample config seem reversed to my understanding (host being external IP and lan_host being internal IP).

    Any help or examples you can shoot my way would be very helpful :)