Skip to main content
8 votes

Trying to install MySQL: Package 'mysql-server' has no installation candidate

mysql has been replaced by mariadb in Debian10. Try default-mysql-server - although you can use mariadb. PS You can see what is available on your distribution e.g. apt-cache search mysql-server
Milliways's user avatar
  • 61k
7 votes
Accepted

Raspbian Stretch with MariaDB

I am running Apache, PHP, MyAdmin and MariaDB on a fresh install of Raspbian Stretch Lite using this sequence, and it works perfectly. Update sudo apt-get update && sudo apt-get upgrade ...
Dr.Rabbit's user avatar
  • 1,018
6 votes
Accepted

MySQL initial installation

mariadb by defaults uses UNIX_SOCKET plugin to authenticate user root. https://mariadb.com/kb/en/mariadb/unix_socket-authentication-plugin/. It works by retrieving uid of the process that has ...
hcheung's user avatar
  • 845
6 votes
Accepted

How to connect MySQLdb in Python 3?

You have to install the MySQLdb package: sudo apt-get update then sudo apt-get install python3-dev libmysqlclient-dev This took a while and finally: sudo pip3 install mysqlclient now it should ...
bierschi's user avatar
  • 340
5 votes
Accepted

I cannot install a very popular component, libmysqlclient-dev. What's wrong?

Debian Stretch changed libmysqlclient-dev to libmariadbclient-dev. MariaDB is a fork of MySQL that's more friendly in the open source world. It's compatible as a drop-in replacement, although you ...
ben_nuttall's user avatar
  • 2,461
4 votes
Accepted

mysqldump command not found when Backing up MYSQL Database

mysqldump is part of mysql / mariadb client packages. For Raspbian Jessie install package 'mysql-client', for Stretch you need 'mariadb-client'
Dirk's user avatar
  • 3,541
4 votes

Use actual MySQL on Raspbian Stretch instead of MariaDB

MariaDB is a drop-in replacement for MySQL and should be mostly compatible to it. Unless you need a very specific feature of MySQL, MariaDB should work just fine. For more details about the ...
flokoe's user avatar
  • 321
3 votes

Can`t install mysql-server on my Raspberry Pi running Stretch

I had the same problem with not being asked to enter the root password during installation. I found the answer here: Raspbian Stretch with MariaDB Note that even though mysql -u root -p does not ...
Mathias Conradt's user avatar
3 votes

Linux programming concept approach

1) to be able to update the pi, I have set up scripts that check git-lab API once a day and download the repo when there is a new version. is this common, is it acceptable? Yes, also you can ...
Mohi Rostami's user avatar
  • 4,349
3 votes
Accepted

Trouble installing MySQL

Use apt-cache to look for likely candidates. apt-cache search mysql-server mariadb-server-10.5 - MariaDB database server binaries mariadb-server-core-10.5 - MariaDB database core server files default-...
joan's user avatar
  • 71.5k
2 votes

No distributions found at all for mysql-connector-python

I suggest you always use packages from the official Raspbian repositories when possible. They will have been tested and will be compatible with the other installed libraries. apt-cache search mysql |...
joan's user avatar
  • 71.5k
2 votes

Unable to install mysql

I solved this problem replace php5-mysql by the php version installed. The php version is show with: $sudo php --version PHP 7.0.19-1 (cli) (built: May 11 2017 14:04:47) ( NTS ) Copyright (c) 1997-...
Jaime Andrés Hurtado Giraldo's user avatar
2 votes
Accepted

unmet dependencies for php5-mysql

php5-mysql is available in the previous version Jessie and NOT in Stretch. But Owncloud should be able to use php7 (php-mysql)! Ref.: https://owncloud.org/blog/php-7-is-here-and-owncloud-is-ready/
MatsK's user avatar
  • 2,802
2 votes

Can`t install mysql-server on my Raspberry Pi running Stretch

I too have had issues with MySQL so many that I dont use it anymore on the Rpi. A drop in replacement is MariaDB, all your of scripts will work as it uses the same syntax. Also install PHPMyadmin ...
Dr.Rabbit's user avatar
  • 1,018
2 votes
Accepted

Install MariaDB 10.2 on Raspbian Stretch

As you can see here, MariaDB's 10.2 builds are only for i386 (32-bit), amd64 (64-bit) and ppc64el (PowerPC). Your Pi has an ARM processor which needs a particular build for that architecture. ...
Aurora0001's user avatar
  • 6,332
2 votes

PHP5, MySQL & MySQLAdmin issues on latest raspbian stretch release

You can downgrade your raspberry from Stretch to Jessie. sudo nano /etc/apt/preferences and add following lines: Package: * Pin: release a=oldstable Pin-Priority: 1001 And update upgrade apt-...
2CoB9's user avatar
  • 78
2 votes

How do I use Raspberry Pi to create a web application for my sensors?

NOTE: This question is dangerously close to being an opinion question, which is more appropriate for Reddit. But I've tried to cast this answer as a "here's a working example". And you yourself have ...
OyaMist's user avatar
  • 1,119
2 votes
Accepted

Connection to MySQL database does not work

By default, the MariaDB server listens for TCP/IP connections on a network socket bound to a single address [...] In Debian [...] the default bind_address is 127.0.0.1, which binds the server to ...
Fabian's user avatar
  • 1,278
2 votes

How do I build Qt's mysql-plugin on Raspbian Buster

I found a solution although this is not the straightforward way to compile all at once. First I compiled and installed Qt 5.12.4 without the MySQL driver plugin as described in the tutorial ...
elnacho's user avatar
  • 43
2 votes

Wordpress not working after PHP update

With Raspbian Buster you will find the needed sql extension in its repository with apt list *php*sql*. Just install it with: rpi ~$ sudo apt install php7.1-mysql
Ingo's user avatar
  • 42.4k
1 vote

How do I build Qt's mysql-plugin on Raspbian Buster

On my build ouput MySQL did work according to my output ( but can't test as i get errors regarding OpenGl when i start my compiled application ) I compiled on on a 4GB Pi4 with the Raspbian Buster ...
Markus Ippy's user avatar
1 vote
Accepted

Installing Mysql 8 on a Raspberry Pi 3 B+

sudo apt-get install software-properties-common -y sudo add-apt-repository ppa:lars-tangvald/mysql-8.0 sudo apt-get update sudo apt-get install mysql-server It consumes more memory than MySQL 5 SWAP ...
user96484's user avatar
1 vote

How to upload data from raspberry pi to MySQL, geting errors

Your SQL insert statement is not inserting the temperature and humidity values. In the VALUES clause, the temp and hum variables are not being replaced by their values. See documentation for Python ...
OyaMist's user avatar
  • 1,119
1 vote

insert sensor data in mysql to python

You are sending the string data to MySQL where you should be sending the string 1.5. You need to interpolate the value of your variable with that name into the string before you send it. Try ...
Brick's user avatar
  • 1,375
1 vote

MySQL vs SQLite on OSMC (Kodi) install

Even if you could, why would you? If you want to work with a sqlite database you'd use a python sqlite library. Also you wouldn't want to test with kodi's sqlite database. You can create a new sqlite ...
ewrewThw's user avatar
1 vote

How to connect MySQLdb in Python 3?

This 3 commands solved my issue with importing the module named 'MySQLdb' sudo apt-get update sudo apt-get install python3-dev **default-libmysqlclient-dev** sudo pip3 install mysqlclient
djsreeraj's user avatar
  • 111
1 vote

Win 10 IoT + apache + php + mysql + ssl?

Everything you assume from traditional Windows systems is irrelevant in IoT Core. Wintel binaries like apache.exe , php.exe and mysql.exe are positively unwelcome and simply won't work. Windows 10 ...
flakeshake's user avatar
  • 6,214
1 vote

Unable to install mysql

Using the command apt-cache search mysql | grep mysql you'll find exactly which the versions of php and php-mysql might be used. In my case (Raspbian 8.0 Jessie) I have php5 and php5-mysql.
Teodor Petrut's user avatar
1 vote

Unable to install mysql

I managed to install with: sudo apt-get install php-mysql It appears that PHP 7 packages are then installed instead of the 5 version.
A. Flora's user avatar
1 vote
Accepted

Install Python Module pyodbc on PI?

Whenever possible use apt-get to install packages on Raspbian. You can then be sure the package will be consistent with the rest of the installed packages. Search for candidates as follows $ apt-...
joan's user avatar
  • 71.5k

Only top scored, non community-wiki answers of a minimum length are eligible