0

Stackoverflow. I am struggling for a past couple of days to install mySQL on my raspberry pi 2 :/ I am not Debian 7 (Wheezy) and there is no way I can change the distribution, have to work with that. So, i need to install MySQL version 5.5 or greater, or MariaDB and i have tried installing both, but none works.
When installing MariaDB, following their documentation, when i get to the point

sudo apt-get install mariadb-server

Am getting an error:

The following packages have unmet dependencies:
 mariadb-server : Depends: mariadb-server-10.0 (= 10.0.32+maria-1~wheezy) but it is not installable

Tried googling and looking for similar cases, but can't find anything which would work.
With mySQL things are even worst. Using their documentation and MySQL APT Repository and tutorials doing following steps:

wget https://dev.mysql.com/get/mysql-apt-config_0.8.8-1_all.deb
dpkg -i mysql-apt-config_0.8.8-1_all.deb (choosing mysql 5.6)
apt-get update

It shows error:

apt-get update
Hit http://mirror.zol.co.zw wheezy Release.gpg
Hit http://mirror.zol.co.zw wheezy Release
Hit http://mirror.zol.co.zw wheezy/main Sources
Hit http://mirror.zol.co.zw wheezy/main amd64 Packages
Hit http://mirror.zol.co.zw wheezy/main i386 Packages
Ign http://mirror.zol.co.zw wheezy/main Translation-en_GB
Ign http://mirror.zol.co.zw wheezy/main Translation-en
Hit http://archive.raspberrypi.org wheezy Release.gpg
Hit http://raspberrypi.collabora.com wheezy Release.gpg
Hit http://raspberrypi.collabora.com wheezy Release
Get:1 http://repo.mysql.com wheezy Release.gpg [173 B]
Hit http://archive.raspberrypi.org wheezy Release
Hit http://raspberrypi.collabora.com wheezy/rpi armhf Packages
Hit http://archive.raspberrypi.org wheezy/main armhf Packages
Get:2 http://repo.mysql.com wheezy Release [24.1 kB]
Get:3 http://repo.mysql.com wheezy/mysql-5.6 Sources [859 B]
Ign http://raspberrypi.collabora.com wheezy/rpi Translation-en_GB
Ign http://raspberrypi.collabora.com wheezy/rpi Translation-en
Ign http://archive.raspberrypi.org wheezy/main Translation-en_GB
Ign http://archive.raspberrypi.org wheezy/main Translation-en
Fetched 25.2 kB in 5s (4,900 B/s)
W: Failed to fetch http://repo.mysql.com/apt/debian/dists/wheezy/Release  Unable                                                            to find expected entry 'mysql-apt-config/binary-armhf/Packages' in Release file                                                            (Wrong sources.list entry or malformed file)

E: Some index files failed to download. They have been ignored, or old ones used                                                            instead.

And if i try:

apt-get install mysql-community-server
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package mysql-community-server

Please help, any help would be very appreciated!

Ilja Leiko
  • 426
  • 2
  • 7
  • 22

1 Answers1

2

There doesn't seem to be any package in official debian repo in the name mysql-community-server. I found mysql-server package instead. https://packages.debian.org/wheezy/mysql-server.

So try this:

  • Add official debian repo to your sources list (i.e. add deb http://security.debian.org/debian-security wheezy/updates main to the file /etc/apt/sources.list)
  • sudo apt-get update
  • sudo apt-get install mysql-server
Ambady Anand S
  • 76
  • 1
  • 11
  • Oh, it shows the same error...sudo apt-get install mysql-server ... E: Unable to locate package mysql-server – Ilja Leiko Oct 11 '17 at 06:17
  • Try following this guide step-by-step: https://dev.mysql.com/doc/mysql-apt-repo-quick-guide/en/ – Ambady Anand S Oct 11 '17 at 06:22
  • Or simply try: `sudo apt-get install mysql-server-5.5` – Ambady Anand S Oct 11 '17 at 06:25
  • Thank you for your reply. Ambady Anand S, that's the exact instruction i was going through and am receiving "W: Failed to fetch http://repo.mysql.com/apt/debian/dists/wheezy/Release Unable". And sudo apt-get install mysql-server-5.5 still shows " Couldn't find any package by regex 'mysql-server-5.5'" – Ilja Leiko Oct 11 '17 at 06:30
  • Okay, try adding official debian repo to your sources list. i.e. add `deb http://security.debian.org/debian-security wheezy/updates main` to the file `/etc/apt/sources.list`, then run `sudo apt-get update` and then `sudo apt-get install mysql-server-5.5`. I hope that should work. – Ambady Anand S Oct 11 '17 at 06:44
  • Thank you, Ambady, the installation has started, but i have got an error at the end [screenshoot](https://i.imgur.com/aypingh.png). i suppose the package did not get installed properly. – Ilja Leiko Oct 11 '17 at 07:07
  • Oh, try `sudo apt-get -f install` then. – Ambady Anand S Oct 11 '17 at 07:13
  • I just noted the permission denied error in the screenshot, so try this first `sudo mount -o remount,exec /tmp` and run the install command again. – Ambady Anand S Oct 11 '17 at 07:21
  • Shut, still not... The same error as on screen shoot. I have also noticed that it argues that: WARNING: The following packages cannot be authenticated! mysql-common libmysqlclient18 libdbd-mysql-perl mysql-client-5.5 mysql-server-5.5 Install these packages without verification [y/N]? y could that be a problem? I have tried googling and trying different solution for verification, but no luck for now – Ilja Leiko Oct 11 '17 at 07:22
  • Tried: purging, sudo mount -o remount,exec /tmp, sudo apt-get -f install mysql-server-5.5... still the same error [new screenshoot](https://i.imgur.com/TIZKS1n.png) – Ilja Leiko Oct 11 '17 at 07:28
  • I think it's better to start a new thread on this. You may also check similar issues like this: https://askubuntu.com/questions/457923/why-did-installation-of-mysql-5-6-on-ubuntu-14-04-fail?noredirect=1&lq=1 – Ambady Anand S Oct 11 '17 at 07:34