Upgrading to MYSQL 8 - MAMP
Asked Answered
B

1

17

I have installed MAMP on my MAC machine and I am trying to upgrade it to use MySQL 8. However, I am not having any luck. I have tried following script but database migration fails.

Also, sequelPro fails to connect to DB but, phpmyadmin has no issue connecting.

#!/bin/sh

curl -OL https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.17-macos10.14-x86_64.tar.gz
tar xfvz mysql-8.0.*

echo "stopping mamp"
sudo /Applications/MAMP/bin/stop.sh
sudo killall httpd mysqld

echo "creating backup"
sudo rsync -arv --progress /Applications/MAMP ~/Desktop/MAMP-Backup

echo "copy bin"
sudo rsync -arv --progress mysql-8.0.*/bin/* /Applications/MAMP/Library/bin/ --exclude=mysqld_multi --exclude=mysqld_safe 

echo "copy share"
sudo rsync -arv --progress mysql-8.0.*/share/* /Applications/MAMP/Library/share/

echo "fixing access (workaround)"
sudo chmod -R o+rw  /Applications/MAMP/db/mysql/
sudo chmod -R o+rw  /Applications/MAMP/tmp/mysql/
#sudo chmod -R o+rw  "/Library/Application Support/appsolute/MAMP PRO/db/mysql/"

echo "starting mamp"
sudo /Applications/MAMP/bin/start.sh

echo "migrate to new version"
/Applications/MAMP/Library/bin/mysql -u root --password=root -h 127.0.0.1
Buckra answered 16/9, 2019 at 11:21 Comment(8)
did you fix it?Shirtmaker
@flakerimi I'm not sure, but Sequel Pro is having issues with MySQL 8, not to the MAMP. I had 8 version install with Docker on my macbook and Sequel still was having issues. Used navicat for 8th version.Lovelace
The last I read, SequelPro does not support MySQL 8, I use TablePlus for that.Anoxia
I'm receiving the following error when running this script: ERROR 2003 (HY000): Can't connect to MySQL server on '127.0.0.1' (61). Any ideas?Roadstead
Could you tell us what all you tried? for suppose: did make sure that your MySQL 8 installation is working independently without MAMP; did you use the mysqldump command to export your databases from the old version, and then import them into the new MySQL 8 version.Birthday
@Birthday I performed a full backup of the necessary databases using mysqldump before upgrading in MAMP. After the upgrade, I restored the databases from the backup file.Buckra
As MySQL 8 having more feature introduce and one of them is Authentication, as you stated that using phpmyadmin you are able to connect while using sequelPro fails. One settings require to perform on my.cnf file as stated below. After that you can restart your mysql service and check also make sure that your root user can be accessible with proper host with password and grant already set up. [mysqld] default-authentication-plugin=mysql_native_password Please let me know does this solve your problem.Batfish
"database migration fails" - what does that mean? Are you facing any specific error message?Washtub
B
0

As MySQL 8 having more feature introduce and one of them is Authentication, as you stated that using phpmyadmin you are able to connect while using sequelPro fails. One settings require to perform on my.cnf file as stated below. After that you can restart your mysql service and check also make sure that your root user can be accessible with proper host with password and grant already set up.

[mysqld]
default-authentication-plugin=mysql_native_password

Please let me know does this solve your problem.

Batfish answered 19/4 at 7:10 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.