Skip to content

Instantly share code, notes, and snippets.

@camsaul
Created July 11, 2017 19:25
Show Gist options
  • Save camsaul/7722db14cc078a7fc776808f30c718a9 to your computer and use it in GitHub Desktop.
Save camsaul/7722db14cc078a7fc776808f30c718a9 to your computer and use it in GitHub Desktop.
fix busted MySQL
#! /bin/bash
# kill the server
pkill -KILL mysqld
# drop all the DBs, logfiles, and other busted data
rm -rf /usr/local/var/mysql/*'@002'*
rm /usr/local/var/mysql/ib*
# now restart the server
mysqld
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment