1. Management Preparation Work
1) Manage Database preparation
Download related software
Mysql-workbench-community-6.3.10-macos-x86_64.dmg
- Oracle website
- MySQL official website
MySQL Reference Manual
MySQL database configuration software, password: v6j7.
2) Management database considerations
- Download the relevant software in advance, and the installation directory is best installed in the full English path. If the path has a Chinese name, there may be some inexplicable problems.
3) Sample Management environment
- MacOS 10.11.6
- MacOS 10.13.3
2. Download and install MySQL Workbench
- MySQL Workbench is an ER/database modeling tool designed for MySQL.
2.1 Download MySQL Workbench
Visit the MySQL website and you will see a "DOWNLOAD" click under "MySQL Workbench" on the page.
Then choose the same version after the server to download, there seems to be only one version.
2.2 Installing MySQL Workbench
After the download is complete, the installation is simple and can be installed by double-clicking. After the installation is complete, you can see the Mysqlworkbench.app program in the "Application" and double click to open it. The MYSQL Workbench is installed here.
3, Management configuration MySQL
Click the plus sign (?) behind MySQL Connections. ), click to see a "Setup New Connection" dialog, click OK after filling out Connection Name. To complete a connection to the local database.
After the completion of the main interface will appear the connection just established, such as.
Click on the connection name or select a connection and click "Open Connection" to enter the password to enter the interface of the operation database.
All of these prerequisites are for the database service to be opened and set up in MySQL in System Preferences.
4. FAQ 4.1 Blank Password Login
On the network, widely circulated this conclusion, MySQL default account is root, the default password is empty. When I click OK, "Login access Denied" is indicated. Google, find a solution: through the mysqld_safe
instructions to allow MySQL to log in without verification, after the successful login, using MySQL workbench to modify the user password.
The solution for MySQL root password forgetting or permissions error on MAC is shown in the MySQL database configuration section of this article.
4.2 Anonymous User Login
If you are prompted for Access denied "@ ' localhost ' to database ' MySQL ' at logon, the reason is that there is an anonymous user in MySQL, and if we do not remove anonymous users, even if you log on with another user, will automatically jump in using anonymous users. Workaround reference:
Method One:
1> Close MySQL
# service mysqld stop
2> Masking Permissions
# mysqld_safe --skip-grant-table
- Screen appears: Starting demo from .....
3> opens a new terminal input
# mysql -u root mysqlmysql> UPDATE user SET Password=PASSWORD('newpassword') where USER='root';mysql> FLUSH PRIVILEGES; // 记得要这句话,否则如果关闭先前的终端,又会出现原来的错误mysql> \q
Method Two:
1> Close MySQL
# service mysqld stop
2> Masking Permissions
# mysqld_safe --skip-grant-table
- Screen appears: Starting demo from .....
3> opens a new terminal input
# mysql -u root mysqlmysql> delete from user where USER='';mysql> FLUSH PRIVILEGES; // 记得要这句话,否则如果关闭先前的终端,又会出现原来的错误mysql> \q
Ios-mac MySQL Database Management (relational database management system)