By chris324769
Have a relatively default latest Ubuntu server (16.04) running LEMP.
Unlike all the other wonderful step by step tutorials the page here: https://www.digitalocean.com/community/tutorials/switching-to-mariadb-from-mysql simple said to uninstall (even though commenters said not necessary) and then install and provided a link another website without any further details. None the less, installed following those instruction.
When installing using the instructions on the MariaDB site: https://downloads.mariadb.org/mariadb/repositories/#mirror=digitalocean-nyc&distro=Ubuntu&distro_release=xenial--ubuntu_xenial&version=10.1 all steps work except the last when it actually tries to install.
$ sudo apt install mariadb-server Reading package lists… Done Building dependency tree Reading state information… Done
Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming.
The following information may help to resolve the situation: The following packages have unmet dependencies: mariadb-server : Depends: mariadb-server-10.1 (= 10.1.17+maria-1~xenial) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
I assume this must be a common issue since I’m using the latest stable Ubuntu and using the latest stable MariaDB. What am I missing?
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!
I got it working after I purged all mysql things and removed all mysql directories in /var/lib:
$ rm -rf /var/lib/mysql*
Remember to backup your database if it has any important information!
I solved this issue by following this solution directly with my droplet LEMP ubuntu 16.04 How to Drop-In replace MySQL with MariaDB?
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.