Question

Access Digital Ocean Managed MySQL Database through phpmyadmin

How can I connect to a Managed Digital Ocean Database? I tried started a new droplet using the one-click PHPMyAdmin and altered the /etc/phpmyadmin/config.inc.php with the following

$i++;
$cfg['Servers'][$i]['host']          = '';
$cfg['Servers'][$i]['port']          = '';
$cfg['Servers'][$i]['connect_type']  = 'tcp';
$cfg['Servers'][$i]['extension']     = 'mysql';
$cfg['Servers'][$i]['compress']      = FALSE;
$cfg['Servers'][$i]['auth_type']     = 'config';
$cfg['Servers'][$i]['user']          = '';
$cfg['Servers'][$i]['password']      = '';

Obviously I filled in the blanks with the information provided in the DB dashboard.

And yes I authorized the droplet to connect in the security settings.


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

hey mbrantley,

you have to ForeceSSL to do that edit /etc/phpmyadmin/config.inc.php

and add this line at the end of the file

$cfg['ForceSSL'] = true;

also set auth_type to cookie

$cfg['Servers'][$i]['auth_type'] = 'cookie';

hopefully, this will solve your issue.

cheers, Ali

Hi @mbrantley,

Our below community article can guide you in setting up and connecting to MySQL Managed database via phpMyAdmin with SSL.

https://www.digitalocean.com/community/tutorials/how-to-connect-to-mysql-managed-database-via-phpmyadmin

I hope this helps!

Regards, Rajkishore

Hello,

There are a couple of things that I could suggest:

  • Make sure that you are using the latest PHP version
  • Make sure that you are using mysql_native_password and not caching_sha2_password
  • If this still does not exist, I would recommend installing the latest version of PHPMyAdmin as described here rather than using the 1-Click installation:

https://www.digitalocean.com/community/questions/how-to-install-manually-phpmyadmin-on-ubuntu

This will allow you to have the latest PHPMyAdmin version which is compatible with MySQL 8.

Hope that this helps. Regards, Bobby