參觀我的【 伊生活小舖】

2015年12月14日 星期一

Installing MySQL on Mac OS X El Capitan 10.11

Download the latest version of MySQL available from the official web site. At time of writing this was 5.7.9 and the description didn’t say it was for 10.11 – but it works fine. Choose the DMG package for easiest installation. You don’t have to sign up to the web site, just click “No thanks, just start my download” beneath the sign up box.
Once downloaded, run the installer. At the end of the installer you will be presented with a dialog of the automatically created root password. Take a note of this.

Open up System Preferences, and select the new MySQL icon.
From here you can start and stop the service, and you can set it to start automatically on startup. Go ahead and start the service.

MySQL is installed in to:
Open up a Terminal window and change to the MySQL folder:
cd /usr/local/mysql/bin/
Run the MySQL Secure Installation and enter the password you were given earlier (please note, that it may first prompt you for your system password):
sudo ./mysql_secure_installation
It will warn you that the root password has expired. This is your opportunity to set your own. Enter it twice.
Follow through the remaining questions answering yes or no, depending on your environment. You can then manage your MySQL databases in your preferred method. 
All done!


Ratings and Recommendations by outbrain