在mac電腦上安裝mysql 5.7需要遵循以下步驟:
1.進入官網https://dev.mysql.com/downloads/mysql/下載mac版的mysql 5.7安裝包 2.打開終端,使用以下命令來安裝homebrew: /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" 3.使用brew命令安裝mysql 5.7: brew install mysql@5.7 4.啟動mysql服務: brew services start mysql@5.7 5.檢查mysql是否安裝成功: mysql --version 6.登錄mysql: mysql -uroot 7.創(chuàng)建新用戶并授權: CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'password'; GRANT ALL PRIVILEGES ON *.* TO 'newuser'@'localhost';
以上就是mac mysql 5.7的安裝教程,希望對你有所幫助。