Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Complete steps of installing mysql5.7.19 under Mac (illustrated in detail)

2025-04-11 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Complete steps to install mysql5.7.19 under Mac

1. Download from the official website:

Https://dev.mysql.com/downloads/mysql

two。 Install mysql

After the download is complete, click install, confirm all the way, and wait for the installation to succeed.

Command line operation

To find the iTerm open in the application, first run the following two commands:

Alias mysql=/usr/local/mysql/bin/mysqlalias mysqladmin=/usr/local/mysql/bin/mysqladmin

These two commands are designed to make it easier to run mysql commands by opening iTerm directly, rather than having to enter the mysql installation directory to run them. The next thing you need to do is reset the password.

Reset password command:

Mysqladmin-u root-p password newpass

Newpass is your new password.

After running the command to reset the password, you are prompted to enter the old password. Students who have installed mysql5.6 or previous versions know that the first run of mysql will assign a default password to root users: root, the old password is root. But now if you type root, the system says the password is wrong, what's going on?

The original version 5.7 will no longer assign a default password to root users, but will give you a temporary password. If you are careful, a temporary password will pop up for you to save after you successfully install mysql. If you don't save it, it doesn't matter, it will be in the notification bar on the right, as shown in the picture.

The password is: 98e4) yoEk%w2

Enter the temporary password, change the password successfully, and log in with the new password:

Mysql-u root-p

Enter, new password, enter, login successful!

Now you can write your sql command!

3. View statu

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report