简体   繁体   中英

Ubuntu "E: Unable to locate package mysql"

Can't solve the problem because nothing helps. Try to install mysql but package is not found. gedit and some other packages looks the same.

Firstly repositories were with subdomain 'by.' (because of regional settings). But I changed them to main server without subdomain. Maybe this caused problems?

I use xubuntu 16.04 xenial xerus.

source.list is

# 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 update , apt-get upgrade doesn't help

There is no package with the name of 'mysql' in the repositories.

If you would like to to connect other mysql servers, you need the mysql-client package: sudo apt-get install mysql-client .

If you want to host a database you need the mysql-server package: sudo apt-get install mysql-server .

Installation guide: https://www.digitalocean.com/community/tutorials/how-to-install-mysql-on-ubuntu-16-04

sudo apt-get update && sudo apt-get dist-upgrade

then

sudo apt-get install mysql-server

Try using deb http://kali.download/kali/ kali-rolling main contrib non-free in your sources.list file.

Then run apt update & upgrade

then run apt install mysql-server

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM