/usr/bin/dpkg returned an error code (1)

I’ve recently upgraded to Ubuntu 20.04.1 LTS and it tells me that mySQL 8 didn’t update successfully. When I try to follow steps to “Fix” the error I keep getting the same error:

dpkg: error processing package mysql-server (–configure): dependency problems - leaving unconfigured Errors were encountered while processing: mysql-server-8.0 mysql-server

Please help!

Show comments

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 mirshakil

Would you mind sharing more information about the issue that you’re currently experiencing?

Regards, Alex

Hi, @davidboudia You can use the following to remove any redundant dependency issues and install a functioning MySQL package

Note: I will strongly recommend you to take a snapshot of the droplet before executing any commands. Further troubleshooting the issue can cause issues with other services and it’s good to have a copy of the current state of the droplet.

sudo apt-get clean
sudo apt-get purge mysql*
sudo apt-get update
sudo apt-get install -f
sudo apt-get install mysql-server-5.7
sudo apt-get dist-upgrade

This should sort the issue for you. Let us know how it goes.

Hope that this helps! Regards, Alex