Skip to content

Instantly share code, notes, and snippets.

@starkcoffee
Created June 24, 2014 23:11
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 starkcoffee/dd926ad4acbefdf51f69 to your computer and use it in GitHub Desktop.
Save starkcoffee/dd926ad4acbefdf51f69 to your computer and use it in GitHub Desktop.
Restarting mysql on mac, resetting root password
> mysql.serverstop --skip-grant-tables
> mysql
mysql> UPDATE mysql.user SET Password=PASSWORD('PASSWORD') WHERE User='root';
mysql> FLUSH PRIVILEGES;
mysql> exit;
> mysql.server stop
> mysql.server start
Sources:
http://robots.thoughtbot.com/starting-and-stopping-background-services-with-homebrew
http://dev.mysql.com/doc/refman/5.0/en/resetting-permissions.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment