我尝试使用命令安装 mysql 服务器apt-get install mysql-server mysql-common
但输出是:
Reading package lists... Done
Building dependency tree
Reading state information... Done
mysql-common is already the newest version (5.8+1.0.2).
The following additional packages will be installed:
default-mysql-server mariadb-client-10.1 mariadb-client-core-10.1
mariadb-common mariadb-server-10.1 mariadb-server-core-10.1
Suggested packages:
mariadb-test netcat-openbsd tinyca
The following NEW packages will be installed:
default-mysql-server mariadb-client-10.1 mariadb-client-core-10.1
mariadb-common mariadb-server-10.1 mariadb-server-core-10.1 mysql-server
0 upgraded, 7 newly installed, 0 to remove and 0 not upgraded.
Need to get 18.8 MB/18.8 MB of archives.
After this operation, 169 MB of additional disk space will be used.
Do you want to continue? [Y/n]
如您所见,它不会安装 mysql服务器,但mariadb-server-10.1为什么?
我想要mysql而不是mariadb。
来源列表:
deb http://ftp.fr.debian.org/debian/ stretch main contrib non-free
deb-src http://ftp.fr.debian.org/debian/ stretch main contrib non-free
# Security
deb http://security.debian.org/ stretch/updates main contrib non-free
deb-src http://security.debian.org/ stretch/updates main contrib non-free
# Backports
deb http://ftp.debian.org/debian/ stretch-backports main contrib non-free
MariaDB 是 MySQL。引用MariaDB 的维基百科页面:
据报道,MariaDB 具有比 MySQL 更好的性能,并且许可条件限制较少。出于这个原因,现在所有主要的 Linux 发行版都使用 MariaDB 而不是 MySQL。它是完全兼容的,每个 MySQL 客户端都可以连接到 MaraDB 并且不会注意到任何差异,因此没有理由更喜欢 MySQL 而不是 MariaDB。