Installing MariaDB on Debian 6 (Squeeze)

Had some trouble installing MariaDB on Debian 6. The system was pretty much a vanilla Lenny (hadn’t used it much that’s why) upgraded to Squeeze only one week ago – and I wanted to install MariaDB instead of MySQL.

This KB entry at AskMonty gave me some guidance, but apt-get simply did not want to install mysql-common from the MariaDB package repository. Now, with the help of knielsen from the #maria channel over at irc.freenode.net, I managed to figure out how to work around it. Instead of apt-get I used aptitude.

The first time around with:

$ sudo aptitude install mariadb-server-5.2 mysql-common

I chose yes, when asked whether the offered solution should be tried:

$ sudo aptitude install mariadb-server-5.2 mysql-common
The following NEW packages will be installed:
  libdbd-mysql-perl{a} libdbi-perl{a} libhtml-template-perl{a}
  libmariadbclient16{ab} libmysqlclient16{a} libnet-daemon-perl{a}
  libplrpc-perl{a} mariadb-client-5.2{ab} mariadb-client-core-5.2{ab}
  mariadb-server-5.2{b} mariadb-server-core-5.2{a}
  mysql-common psmisc{a}
0 packages upgraded, 13 newly installed, 0 to remove and 0 not upgraded.
Need to get 24.5 MB/24.6 MB of archives. After unpacking 59.4 MB will be used.
The following packages have unmet dependencies:
  mariadb-server-5.2: PreDepends: mariadb-common which is a virtual package.
  mariadb-client-5.2: Depends: mariadb-common which is a virtual package.
  libmariadbclient16: Depends: mariadb-common which is a virtual package.
                      Depends: libmysqlclient16 (= 5.2.5-mariadb99~squeeze)
                               but 5.1.49-3 is to be installed.
  mariadb-client-core-5.2: Depends: mariadb-common which is a virtual package.
The following actions will resolve these dependencies:

     Keep the following packages at their current version:
1)     libmariadbclient16 [Not Installed]
2)     mariadb-client-5.2 [Not Installed]
3)     mariadb-client-core-5.2 [Not Installed]
4)     mariadb-server-5.2 [Not Installed]
5)     mariadb-server-core-5.2 [Not Installed]



Accept this solution? [Y/n/q/?]
The following NEW packages will be installed:
  mysql-common psmisc{a}
0 packages upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 119 kB/190 kB of archives. After unpacking 868 kB will be used.
Do you want to continue? [Y/n/?]
Get:1 ftp://mirror.hetzner.de/debian/packages/ squeeze/main psmisc amd64 22.11-1 [119 kB]
Fetched 119 kB in 0s (365 kB/s)
Selecting previously deselected package mysql-common.
(Reading database ... 33260 files and directories currently installed.)
Unpacking mysql-common (from .../mysql-common_5.1.49-3_all.deb) ...
Selecting previously deselected package psmisc.
Unpacking psmisc (from .../psmisc_22.11-1_amd64.deb) ...
Processing triggers for man-db ...
Setting up mysql-common (5.1.49-3) ...
Setting up psmisc (22.11-1) ...

Well, turns out that was wrong. And I should have noticed by the package version of mysql-common. So the second time with the same command as before, I declined the first offer and was offered this:

$ sudo aptitude install mariadb-server-5.2 mysql-common
The following NEW packages will be installed:
  libdbd-mysql-perl{a} libdbi-perl{a} libhtml-template-perl{a}
  libmariadbclient16{ab} libmysqlclient16{a} libnet-daemon-perl{a}
  libplrpc-perl{a} mariadb-client-5.2{ab} mariadb-client-core-5.2{ab}
  mariadb-server-5.2{b} mariadb-server-core-5.2{a}
  mysql-common psmisc{a}
0 packages upgraded, 11 newly installed, 0 to remove and 0 not upgraded.
Need to get 24.4 MB of archives. After unpacking 58.6 MB will be used.
The following packages have unmet dependencies:
  mariadb-server-5.2: PreDepends: mariadb-common which is a virtual package.
  mariadb-client-5.2: Depends: mariadb-common which is a virtual package.
  libmariadbclient16: Depends: mariadb-common which is a virtual package.
                      Depends: libmysqlclient16 (= 5.2.5-mariadb99~squeeze)
                               but 5.1.49-3 is to be installed.
  mariadb-client-core-5.2: Depends: mariadb-common which is a virtual package.

[...]

The following actions will resolve these dependencies:

     Install the following packages:
1)     libmysqlclient16 [5.2.5-mariadb99~squeeze ()]

     Upgrade the following packages:
2)     mysql-common [5.1.49-3 (now, stable) -> 5.2.5-mariadb99~squeeze ()]



Accept this solution? [Y/n/q/?]

… and that looked acceptable. Note that it was now offering to install the correct packages from MariaDB.

So after pressing RETURN to confirm the suggested actions, everything ran smoothly.

// Oliver

This entry was posted in EN, Linux, Unix and unixoid and tagged , . Bookmark the permalink.

One Response to Installing MariaDB on Debian 6 (Squeeze)

  1. Pingback: MariaDB auf Squeeze - Delphi-PRAXiS

Leave a Reply

Your email address will not be published. Required fields are marked *