Can't Import MySQL Database

October 30, 2019 124 views
DigitalOcean Managed MySQL Database

Hi there,

I want to use managed database instead of my own digitalocean vps server.

My server is centos and mysql version is 5.5.5.

I want to import mysql .sql file to new database.
I installed “tablesplus” and chose “import” section. my database is 217mb.
when it imports 20mb, then it gives an error.


after that I tried to connect my managed database from my terminal, to import my sql file.

mysql -u doadmin -p blablabla -h blabla-do-user-blabla-0.db.ondigitalocean.com -P 25060 -D defaultdb

but when use it, it return me that error:

ERROR 1045 (28000): Plugin cachingsha2password could not be loaded: dlopen(/usr/local/Cellar/mariadb/10.4.6//usr/local/Cellar/mariadb/10.4.6/lib/plugin/cachingsha2password.so, 2): image not found

I can’t import my existing sql file to managed database.
isn’t there any way to make it?

1 Answer

Hello,

I believe that your mysql client version might be 5.x and you need 8.x in order to be able to connect to the managed SQL instance.

You can test that by running this command:

mysql -v

If this is indeed the case, I would recommend following the steps on how to sort that out here:

https://www.digitalocean.com/community/tutorials/how-to-connect-to-managed-database-ubuntu-18-04#connecting-to-a-managed-mysql-database

Hope that this helps!
Regards,
Bobby

by Mark Drake
If you're new to working with managed databases, the best way to perform certain tasks, like connecting to the database, may not be self-evident. In this guide, we will go over how to install client programs for a variety of database management systems, including PostgreSQL, MySQL, and Redis, on an Ubuntu 18.04 server. We'll also explain how to use these programs to connect to a managed database instance.
Have another answer? Share your knowledge.