Skip to content

Instantly share code, notes, and snippets.

@BernardoSilva
Created March 19, 2016 18:16
Show Gist options
  • Save BernardoSilva/897f64a53e6a56540fba to your computer and use it in GitHub Desktop.
Save BernardoSilva/897f64a53e6a56540fba to your computer and use it in GitHub Desktop.
Mysql tips on Mac
// How to reset root password for MySQL on mac
mysql.server restart --skip-grant-tables
mysql
UPDATE mysql.user SET Password=PASSWORD('new_root_password') WHERE User='root';
exit
mysql -u root -p
// new_root_password or your password
Can't start MySQL on mac due to `permission deny`?
check if you have a mysql user on your system, or just change the ownership to your users
sudo chown -R you-system-user:your-system-user-group /usr/local/mysql
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment