MySQL has different version. In this article we will be installing the community edition of MySQL
Table of Contents
- Download MySQL Community Edition
- Install MySQL Community Edition
- Start MySQL Server
- Verify MySQL Server Installation
Download MySQL Community Edition
To install MySQL on MacOS follow below steps:
Step 1: Navigate to MySQL Website
Step 2: Click on Downloads in top menu
Step 3: Scroll down and click on MYSQL Community (GPL) Downloads
Step 4: Click on MySQL Community Server
Step 5: Select Following values:
- Select Version: LTS
- Select Operating System: macOS
- Select OS Version: x64 or ARM
Step 6: After above selection, macOS (...) DMG Archive will display. Click on Download
Step 7: It will ask you to Login. It is up to you if you want to login, you can see benefits written on same page. With login download will be faster and there are few more benefits. If you are not interested to login click on No thanks, just start my download.
Install MySQL Community Edition
Step 1: Once the download is finished. Open downloaded DMG file to start installation
Step 2: Double click on .pkg file
Step 3: Click on Allow
Step 4: Click on Continue
Step 5: Scroll to accept License agreement and click on Continue. You will see popup to agree the terms. Click on Agree
Step 6: Click on Install
Enter system password if it asks.
Step 7: On the Configuration screen. Enter root password and click on Finish. Root password you will be using to login to mysql server later, remember it or save it somewhere.
Step 8: Enter System password
Step 9: Click finish. MySQL server is installed successfully.
Start MySQL Server
Once the mysql server is installed. It will automatically start, if you have selected the Start MySQL server... checkbox earlier. To stop or restart you can follow below steps:
Step 1: Click on Apple icon and then System Settings...
Step 2: Scroll up in Left Panel below Search, and click on MySQL.
Step 3: Click on Stop MySQL Server or Start MySQL Server. It will ask for you system password.
Verify MySQL Server Installation
To verify MySQL is successfully installed, follow below steps:
Step 1: Open Terminal and type below command to check mysql version
mysql --version
Step 2: To login to MySQL Server follow below steps:
mysql -u root -p
You will see below screen:
- Log in to post comments