READ only database coherency fix
The document mentionned that we could use the rest of nodes as read only nodes, however the configuration suggest to use only one. Change-Id: I418cd0e0bd00b093356ecca3d949e5ad44ba260e
This commit is contained in:
parent
569d22ee01
commit
9646979e7b
|
@ -112,11 +112,11 @@ If you choose to run haproxy for this, you can use something like the following
|
|||
|
||||
listen db_slave
|
||||
bind 0.0.0.0:3308
|
||||
balance first
|
||||
balance roundrobin
|
||||
option mysql-check
|
||||
server server-1 server-1.with.the.fqdn check inter 5s downinter 15s fastinter 2s resolvers cluster backup id 3
|
||||
server server-2 server-2.with.the.fqdn check inter 5s downinter 15s fastinter 2s resolvers cluster id 1
|
||||
server server-3 server-3.with.the.fqdn check inter 5s downinter 15s fastinter 2s resolvers cluster backup id 2
|
||||
server server-1 server-1.with.the.fqdn check inter 5s downinter 15s fastinter 2s resolvers cluster id 3 backup
|
||||
server server-2 server-2.with.the.fqdn check inter 5s downinter 15s fastinter 2s resolvers cluster id 1 weight 10
|
||||
server server-3 server-3.with.the.fqdn check inter 5s downinter 15s fastinter 2s resolvers cluster id 2 weight 10
|
||||
|
||||
By using two blocks, we can separate the ``read`` only SQL requests (listening on port 3308 here) from ``read/write``
|
||||
requests (listening on port 3306 here) and lower down a little bit the load on the first (master) mysql backend.
|
||||
|
|
Loading…
Reference in New Issue