2

When I attempt to install MariaDB Server on my Ubuntu Server 16.04.2 with apt install mariadb-server, I get the following response:

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-10.0 : Depends: libdbi-perl but it is not going to be installed
                       Depends: mariadb-client-10.0 (>= 10.0.29-0ubuntu0.16.04.1) but it is not going to be installed
                       Recommends: libhtml-template-perl but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

I did try on another instance (virtual machine, same HW) of the same OS. Over there I have no issues and the MariaDB seems to be installing fine.

Can you please suggest how I can fix the issue and install MariaDB-server on my Ubuntu?

I tried already:

sudo apt-get autoclean
sudo apt-get autoremove
sudo apt update
sudo apt-get --fix-broken install
sudo apt upgrade
sudo dpkg --configure -a

Thank you.

  • check the source repo list you are using for apt have those packages. – arupgsh Apr 19 '17 at 21:02
  • /etc/apt/sources.list is identical with the working system's one. – Mobby Dick Apr 19 '17 at 21:45
  • did you also check additional repos in /etc/apt/sources.list.d/ – s1mmel Apr 20 '17 at 09:07
  • Did you ever solve this? I'm having the same issue in 16.04.2 and can't fix it – xtian777x May 05 '17 at 23:55
  • Ubuntu 16 is more buggy that 14, and with mysql and mariadb not installing so that you can use python-mysql, means that it wastes a great deal of time for adminstrators. Rackspace only offer Ubuntu 12 with their LAMP stack. If that is the case, Ubuntu 12 and 14 should still be supported. – MagicLAMP Jul 31 '17 at 01:27

1 Answers1

0

Have you tried including the dependencies? Like this:

sudo apt-get install mariadb-server libdbi-perl mariadb-client-10.0

There is already a similar question about this. Take a look at this link: How do I resolve unmet dependencies after adding a PPA?

Regards

  • I did, but it just keeps coming with more and more dependencies. On the other system it automatically selects all dependencies and installs the package.

    `sudo apt-get install mariadb-server libdbi-perl mariadb-client-10.0

    The following packages have unmet dependencies: libdbi-perl : Depends: perlapi-5.22.1 mariadb-client-10.0 : Depends: libdbd-mysql-perl (>= 1.2202) but it is not going to be installed Depends: libterm-readkey-perl but it is not going to be installed E: Unable to correct problems, you have held broken packages.`

    – Mobby Dick Apr 19 '17 at 21:07
  • I think I found the link before and I tried probably everything I did not need the GUI for. – Mobby Dick Apr 19 '17 at 21:54
  • It is a shoot in the dark here, but have you considered using Docker? There are ready images for almost everything, including MariaDB as an official repository. Just download Docker and try this link out: https://hub.docker.com/_/mariadb/ -- You will get rid of these dependency problems for good. All you need is embedded into the container. – Renato Aloi Batista May 12 '17 at 13:30