Question

How to Access the WordPress db after 1-Click Install

I installed a WordPress site on my droplet using 1-click but not I want to access the mysql database and cannot.

I am able to SSH into my droplet and use the mysql command-line tool but I cannot use it to view or reset the mysql root password. How do I do that?

I have found other “solutions” in the tutorials but they have not worked.


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.

Hello there,

We have an article on How To Reset Your MySQL or MariaDB Root Password which you can check right here:

https://www.digitalocean.com/community/tutorials/how-to-reset-your-mysql-or-mariadb-root-password

If this does not work for you, just update this thread and we can work together to get this sorted.

Hope that this helps!

Hi @BenRothman,

Once you SSH and type in mysql in the command line what happens? If you are able to enter MySQL, you can reset the root MySQL user password using the query:

ALTER USER 'root'@'localhost' IDENTIFIED BY 'NewPassword';

Where ‘NewPassword’ should be the new password you want to use. Please bear in mind it still needs to be inside quotes.