Skip to content

Instantly share code, notes, and snippets.

@nicklasos
Created May 30, 2016 10:06
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nicklasos/674068a41fd50aff1de18acca5bf15bb to your computer and use it in GitHub Desktop.
Save nicklasos/674068a41fd50aff1de18acca5bf15bb to your computer and use it in GitHub Desktop.
Mac OS
This is what worked for me on OS X Yosemite running MySql v5.7 (installed from the .dmg).
cd /usr/local/mysql/bin
mysql -u root -p --connect-expired-password
(Enter the temporary password generated by the installer.)
This gets you into sandbox mode and mysql> prompt. Then set desired root password with SET PASSWORD:
SET PASSWORD FOR 'root'@'localhost' = PASSWORD('mySuperSecretPassword');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment