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

Install mysql database records on Mac

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

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

Download mysql for mac: https://downloads.mysql.com/archives/community/

Note: I downloaded the community version, and the mysql version should be consistent with your MAC version. Of course, if you have installed other versions of MYSQL before, be sure to uninstall them first.

Double-click mysql-8.0.0-dmr-osx10.11-x86_64.dmg to extract and install.

Continue-> Continue, Agree-> Install. Record the password in the pop-up window.

Enter the system preferences, find mysql, and start the service.

Add mysql commands to the system

(1)。 Enter / usr/local/mysql/bin to see if there is a mysql in this directory

(2)。 Execute vim ~ / .bash_profile

Add the directory of mysql/bin to the file

PATH=$PATH:/usr/local/mysql/bin

When the addition is complete, press esc, and then enter wq to save.

(3)。 Finally, enter source ~ / .bash_profile on the command line

Log in to mysql through mysql-uroot-p and enter the previously saved password

Reset the mysql initial password:

SET PASSWORD FOR 'root'@'localhost' = PASSWORD (' newpassword')

Reference:

1, https://blog.csdn.net/pansanday/article/details/54915916

2, https://www.cnblogs.com/yangjig/p/6014198.html

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