How can I completely uninstall mysql-server and reinstall? - Ask Ubuntu
i upgraded 12.10 16.04 on server. after upgrading (which appears have gone fine), unable login mysql server. such, uninstalled server, , reinstalled using:
apt-get remove mysql-server apt-get install mysql-server
however, seems give me:
renaming removed key_buffer , myisam-recover options (if present) initctl: unable connect upstart: failed connect socket /com/ubuntu/upstart: connection refused insserv: warning: script 'screen-cleanup' missing lsb tags , overrides insserv: default-start undefined, assuming empty start runlevel(s) script `screen-cleanup' insserv: default-stop undefined, assuming empty stop runlevel(s) script `screen-cleanup' job mysql.service failed because control process exited error code. see "systemctl status mysql.service" , "journalctl -xe" details. invoke-rc.d: initscript mysql, action "start" failed. dpkg: error processing package mysql-server-5.7 (--configure): subprocess installed post-installation script returned error exit status 1 setting mysql-client (5.7.16-0ubuntu0.16.04.1) ... dpkg: dependency problems prevent configuration of mysql-server: mysql-server depends on mysql-server-5.7; however: package mysql-server-5.7 not configured yet. dpkg: error processing package mysql-server (--configure): dependency problems - leaving unconfigured processing triggers systemd (229-4ubuntu11) ... processing triggers ureadahead (0.100.0-19) ... errors encountered while processing: mysql-server-5.7 mysql-server
i tried stopping service, uninstalling, purging, , removing /etc/mysql , /var/lib/mysql (after backing up, of course).
i'm @ complete loss why happening now. can't seem recover database data. i've noticed whenever uninstall/reinstall procedure, it's not asking me mysql password, wonder if it's not uninstalled.
to remove config files use
apt-get purge mysql-server\* rm -rf /etc/my.cnf /etc/mysql
if want delete databases well, need delete directory /var/lib/mysql
, too.
Comments
Post a Comment