Skip to content

Instantly share code, notes, and snippets.

@3manuek
Last active November 17, 2015 21:21
Show Gist options
  • Select an option

  • Save 3manuek/de0b5997d39814ef7532 to your computer and use it in GitHub Desktop.

Select an option

Save 3manuek/de0b5997d39814ef7532 to your computer and use it in GitHub Desktop.
MySQL sandbox tutorial
emanuel@3laptop ~/Downloads $ make_replication_sandbox --master_master mysql-5.7.9-linux-glibc2.5-x86_64.tar.gz
installing node 1
installing node 2
# server: 1:
# server: 2:
# server: 1:
# server: 2:
# server: 1:
# server: 2:
Circular replication activated
group directory installed in $HOME/sandboxes/rcsandbox_mysql-5_7_9
// signal=all removed by now
emanuel@3laptop ~/sandboxes/rcsandbox_mysql-5_7_9 $ sudo pkill strace
sudo strace -e trace=file,process,signal,ipc,desc,memory -e signal=all -C -i -v -p 6775 2> testStrace1.log &
sudo strace -e trace=file,process,signal,ipc,desc,memory -e signal=all -C -i -v -p 7176 2> testStrace2.log &
sudo strace -e trace=all -e signal=all -C -i -v -p 6775 -f -t &> testStrace1.log &
sudo strace -e trace=all -e signal=all -C -i -v -p 7176 -f -t &> testStrace2.log &
sudo strace -e trace=poll -e signal=all -C -i -v -p 6775 -f -t -o testStrace1.log &
sudo strace -e trace=poll -e signal=all -C -i -v -p 7176 -f -t -o testStrace2.log &
sudo strace -e trace=read -C -i -v -p 6775 -f -t -o testStrace1.log &
sudo strace -e trace=read -C -i -v -p 7176 -f -t -o testStrace2.log &
emanuel@3laptop ~/sandboxes/rcsandbox_mysql-5_7_9/node1 $ sysbench --test=oltp --oltp-table-size=100 --mysql-db=test --mysql-user=msandbox --mysql-password=msandbox --mysql-socket=/tmp/mysql_sandbox14901.sock --mysql-port=14901 prepare
sysbench --test=oltp --oltp-table-size=1000000 --mysql-db=test --mysql-user=msandbox --mysql-password=msandbox --mysql-socket=/tmp/mysql_sandbox14901.sock --mysql-port=14901 --max-time=60 --oltp-read-only=off --max-requests=0 --num-threads=8 run
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment