We are going to use Homebrew to install MySQL and MySQL Workbench.

  1. In a terminal, check if you have Homebrew installed by running brew --version.
  2. If you don't have it installed, go to brew.sh and run the script on the home page in the terminal.
  3. Run brew update.
  4. To install MySQL run brew install mysql.
  5. To start the MySQL service run brew services start mysql.
  6. Run the security script with mysql_secure_installation.
  7. When asked about using the validate password component you can select either yes or no. In the video below we select no.
  8. Enter a password you will use for the root user. Don't lose this password. Nothing will display in the terminal when you type the password.
  9. Re-enter the password.
  10. Remove anonymous users? Enter yes.
  11. Disallow root login remotely? Enter yes.
  12. Remove test database? Enter either yes or no.
  13. Reload privileges table now? Enter yes.
  14. Install MySQL Workbench with brew install --cask mysqlworkbench.
  15. Open Workbench through Spotlight or the icon in the Applications folder.
  16. If you don't have a connection when opening Workbench, click the + sign, enter a connection name, leave the user as root, and use the password you entered above.

Tags: