Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MySQl 5.7 installation failed on Kubuntu 16.04 [closed]

Configuring mysql-server-5.7 (5.7.11-0ubuntu6) … 
insserv: warning: current start runlevel(s) (empty) of script `mysql' overrides LSB defaults (2 3 4 5). 
insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script `mysql' overrides LSB defaults (0 1 6).
mysql_upgrade: Got error: 2002: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) while connecting to the MySQL server 
Upgrade process encountered error and will not continue. 
mysql_upgrade failed with exit status 11 
dpkg: error with
   mysql-server-5.7 (--configure):

apt-get remove return the same result.

This error come in with upgrade from 15.10 to 16.04

like image 559
kden Avatar asked Apr 22 '16 21:04

kden


People also ask

How do I completely remove MySQL from Ubuntu?

Navigate to Control Panel -> Programs and Features -> MySQL. From there, click on the option to Uninstall. Once MySQL is uninstalled, to completely remove the program, you need to ensure its data directories are removed as well. *Note: you may want to create backups of these directories before deleting them.


1 Answers

It was exactly same for me: runlevel warnings and mysql_upgrade error.

I guess it was because I disabled mysql service, enabling it fixes the problem:

sudo systemctl enable mysql

like image 64
iman Avatar answered Nov 15 '22 04:11

iman