Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to prevent MariaDB to install when installing MySQL-Server?

I am trying to install MySQL Server in a Debian 9 installation and apt-get insists to install this mariadb-client-10.1 through:

sudo apt-get install mysql-server mysql-client

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer     required:
  libmecab2 libtext-template-perl mecab-ipadic mecab-ipadic-utf8 mecab-utils
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
default-mysql-client default-mysql-server mariadb-client-10.1
mariadb-server-10.1
Suggested packages:
mailx mariadb-test netcat-openbsd tinyca
The following NEW packages will be installed:
default-mysql-client default-mysql-server mariadb-client-10.1
mariadb-server-10.1 mysql-client mysql-server
0 upgraded, 6 newly installed, 0 to remove and 0 not upgraded.
Need to get 4,748 B/11.2 MB of archives.
After this operation, 125 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://ftp.jaist.ac.jp/debian stretch/main amd64 default-mysql-    client all 1.0.2 [3,050 B]
Get:2 http://ftp.jaist.ac.jp/debian stretch/main amd64 mysql-client amd64     5.5.9999+default [1,698 B]
Fetched 4,748 B in 0s (92.8 kB/s)
Preconfiguring packages ...
Selecting previously unselected package mariadb-client-10.1.
(Reading database ... 290851 files and directories currently installed.)
Preparing to unpack .../0-mariadb-client-10.1_10.1.26-0+deb9u1_amd64.deb ...
Unpacking mariadb-client-10.1 (10.1.26-0+deb9u1) ...
Selecting previously unselected package mariadb-server-10.1.
Preparing to unpack .../1-mariadb-server-10.1_10.1.26-0+deb9u1_amd64.deb ...
Unpacking mariadb-server-10.1 (10.1.26-0+deb9u1) ...
Selecting previously unselected package default-mysql-client.
Preparing to unpack .../2-default-mysql-client_1.0.2_all.deb ...
Unpacking default-mysql-client (1.0.2) ...
Selecting previously unselected package default-mysql-server.
Preparing to unpack .../3-default-mysql-server_1.0.2_all.deb ...
Unpacking default-mysql-server (1.0.2) ...
Selecting previously unselected package mysql-client.
Preparing to unpack .../4-mysql-client_5.5.9999+default_amd64.deb ...
Unpacking mysql-client (5.5.9999+default) ...
Selecting previously unselected package mysql-server.
Preparing to unpack .../5-mysql-server_5.5.9999+default_amd64.deb ...
Unpacking mysql-server (5.5.9999+default) ...
Setting up mariadb-client-10.1 (10.1.26-0+deb9u1) ...
Processing triggers for menu (2.1.47+b1) ...
Processing triggers for systemd (232-25+deb9u4) ...
Processing triggers for man-db (2.7.6.1-2) ...
Setting up mariadb-server-10.1 (10.1.26-0+deb9u1) ...
Setting up default-mysql-client (1.0.2) ...
Setting up default-mysql-server (1.0.2) ...
Setting up mysql-server (5.5.9999+default) ...
Setting up mysql-client (5.5.9999+default) ...
Processing triggers for systemd (232-25+deb9u4) ...

Is there any way I can install only MySQL-server? Or that MariaDB thing must be installed? Thanks in advance.

like image 971
Sandro Hissao Nakaguma Avatar asked Sep 12 '18 08:09

Sandro Hissao Nakaguma


People also ask

Can I use MySQL instead of MariaDB?

In fact MariaDB is fully compatible with MySQL since it was (and still is) intended to be a perfect replacement for MySQL. A standard MySQL installation comes bundled with a couple of useful tools, such as mysqldump, which is helpful for backups. It can be used with both MySQL and MariaDB.

Do I need to install MySQL before MariaDB?

Within the same base version (for example MySQL 5.5 -> MariaDB 5.5, MySQL 5.6 -> MariaDB 10.0 and MySQL 5.7 -> MariaDB 10.2) you can in most cases just uninstall MySQL and install MariaDB and you are good to go. There is no need to dump and restore databases.

Does MariaDB install MySQL?

MariaDB and MySQL packages conflict because they provide similar files. So, you can only install one of them, either MariaDB or MySQL, but not both. In addition you can also install MySQL commmunity edition (8.0 or 5.7) from the repository maintained by Oracle/MySQL itself.

Why did MySQL become MariaDB?

After the acquisition of MySQL by Oracle, some issues happened with the usage of the database and hence MariaDB was developed. 2. MariaDB : MariaDB is an open source relational database management system (RDBMS) that is a compatible drop-in replacement for the widely used MySQL database technology.


1 Answers

you go to http://repo.mysql.com/ and choose a version

I have debian 9 so I choose

wget http://repo.mysql.com/mysql-apt-config_0.8.15-1_all.deb
sudo dpkg -i mysql-apt-config_0.8.15-1_all.deb

Then you will be asked what you desire to install ... you say mysql Server

enter image description here

then you go as usual ...

sudo apt update 
sudo apt install mysql-server

and the rest you know probably ...

like image 150
Max Muster Avatar answered Oct 08 '22 18:10

Max Muster