Ubuntu" E:无法找到包mysql"

时间:2017-01-29 13:02:17

标签: linux ubuntu

无法解决问题,因为没有任何帮助。尝试安装mysql但找不到包。 gedit和其他一些软件包看起来是一样的。

首先,存储库具有子域' by。' (因区域设置)。但是我将它们更改为没有子域的主服务器。也许这会引起问题?

我使用xubuntu 16.04 xenial xerus。

source.list是

# deb cdrom:[Xubuntu 16.04.1 LTS _Xenial Xerus_ - Release amd64 (20160719)]/ xenial main multiverse restricted universe

deb http://archive.ubuntu.com/ubuntu xenial main restricted    
deb http://archive.ubuntu.com/ubuntu xenial-updates main restricted    
deb http://archive.ubuntu.com/ubuntu xenial universe    
deb http://archive.ubuntu.com/ubuntu xenial-updates universe    
deb http://archive.ubuntu.com/ubuntu xenial multiverse
deb http://archive.ubuntu.com/ubuntu xenial-updates multiverse   
deb http://archive.ubuntu.com/ubuntu xenial-backports main restricted universe multiverse    
deb http://archive.canonical.com/ubuntu xenial partner
deb-src http://archive.canonical.com/ubuntu xenial partner    
deb http://archive.ubuntu.com/ubuntu xenial-security main restricted    
deb http://archive.ubuntu.com/ubuntu xenial-security universe    
deb http://archive.ubuntu.com/ubuntu xenial-security multiverse

apt-get updateapt-get upgrade没有帮助

2 个答案:

答案 0 :(得分:13)

没有名称为' mysql'在存储库中。

如果您想连接其他mysql服务器,则需要mysql-client软件包:sudo apt-get install mysql-client

如果要托管数据库,则需要mysql-server软件包:sudo apt-get install mysql-server

安装指南:https://www.digitalocean.com/community/tutorials/how-to-install-mysql-on-ubuntu-16-04

答案 1 :(得分:1)

sudo apt-get更新&& sudo apt-get dist-upgrade

然后

sudo apt-get install mysql-server