Skip to content

Instantly share code, notes, and snippets.

@nicklasos
Created February 13, 2020 14:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nicklasos/8b10e9f5ad4a30bb5963984fe10c431e to your computer and use it in GitHub Desktop.
Save nicklasos/8b10e9f5ad4a30bb5963984fe10c431e to your computer and use it in GitHub Desktop.
apt-get install percona-toolkit
pt-online-schema-change --print --progress time,5 --max-load Threads_running=500 --critical-load Threads_running=5000 --chunk-time 5 --set-vars "innodb_lock_wait_timeout=600" --nocheck-plan --execute -h {localhost} -u {user} --p "{password}" --alter "ADD {column} varchar(32) DEFAULT NULL" D={database},t={table}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment