Skip to content

Using Primary/Replica modes to conduct tests on multiple instances of DB #328

Answered by sm-shaw
ananthu-dev asked this question in Q&A
Discussion options

You must be logged in to vote

Here is an example:
The system has 2 MariaDB instances running locally so I'm using sockets to connect so one is on /tmp/mariadb.sock and the other /tmp/mariadb2.sock.
I've used the GUI locally to configure and save 2 driver scripts with my options mdbprim.tcl and mdbrep.tcl, this is the difference between them:

diff mdbprim.tcl mdbrep.tcl 
13c13
< set socket "/tmp/mariadb.sock" ;# Maria Socket for local connections
---
> set socket "/tmp/mariadb2.sock" ;# Maria Socket for local connections

I also have a file called mariarun.tcl as follows:

vuset vu 2
vucreate
vurun
runtimer 480
vudestroy

I've then started 2 hammerdb instances and connected the replica to the primary and loaded our cust…

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
1 reply
@ananthu-dev
Comment options

Comment options

You must be logged in to vote
2 replies
@ananthu-dev
Comment options

@sm-shaw
Comment options

Answer selected by sm-shaw
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants