Skip to content

Commit

Permalink
cheatsheet text
Browse files Browse the repository at this point in the history
  • Loading branch information
Shlomi Noach committed Jul 16, 2016
1 parent 6aba76c commit d688cad
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions doc/cheatsheet.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,33 @@ If your master works with SBR, this is the mode to work with. The replica must b

However even with RBR we suggest this is the least master-intrusive operation mode.

```
gh-ost \
--max-load=Threads_running=25 \
--critical-load=Threads_running=1000 \
--chunk-size=1000 \
--throttle-control-replicas="myreplica.1.com,myreplica.2.com" \
--max-lag-millis=1500 \
--user="gh-ost" \
--password="123456" \
--host=replica.with.rbr.com \
--database="my_schema" \
--table="my_table" \
--verbose \
--alter="engine=innodb" \
--switch-to-rbr \
--allow-master-master \
--cut-over=default \
--exact-rowcount \
--default-retries=120 \
--panic-flag-file=/tmp/ghost.panic.flag \
--postpone-cut-over-flag-file=/tmp/ghost.postpone.flag \
[--execute]
```

With `--execute`, migration actually copies data and flips tables. Without it this is a `noop` run.


##### b. Connect to master

If you don't have replicas, or do not wish to use them, you are still able to operate directly on the master. `gh-ost` will do all operations directly on the master. You may still ask it to be considerate of replication lag.
Expand Down

0 comments on commit d688cad

Please sign in to comment.