I've got an issue I've never run across nor seen before, And to be honest, I'm not confident enough to proceed without some input from someone who may have experience with it.
I was trying to uninstall (purge) mysql for a fresh install of it. When I ran this command
sudo apt-get purge mysql I get an error that culminates with this ->
Errors were encountered while processing:
Processing was halted because there were too many errors.
E: Sub-process /usr/bin/dpkg returned an error code (1)
So then I ran this
sudo dpkg --configure -a
And got this ->
Setting up mysql-server-8.0 (8.0.30-0ubuntu0.20.04.2) ...
Failed to stop mysql.service: Unit mysql.service not loaded.
invoke-rc.d: initscript mysql, action "stop" failed.
MySQL has been frozen to prevent damage to your system. Please see /etc/mysql/FROZEN for help
scripts will avoid making changes or starting the daemon until manually
released from this state. See /usr/share/doc/mysql-common/README for
general information about this mode.
In this particular case, an incompatible downgrade attempt has been
detected. This can be resolved in one of two ways:
- Change the contents of /var/lib/mysql/ to contain database data that
is compatible with the currently installed MySQL or variant daemon
version. For example: you could restore from a backup. Alternatively you
could do a dump using a future version binary and then a restore using
the current version binary.
- Switch to a MySQL or variant daemon version that is compatible with
the data currently in /var/lib/mysql/. For example, if you have
attempted a downgrade from mysql-server-5.7 to mysql-server-5.6, you
could "apt install mysql-server-5.7" again.
Please resolve this situation and only then remove the /etc/mysql/FROZEN
symlink. You can then run "dpkg-reconfigure " where
should usually be in the form -server-.
And like I said, I'm not confident enough to proceed without some guidance.
I'm tempted to go into Synaptic and try to remove all mysql* from there but I'm not sure that won't cause different problems.
Anyone have experience with this particular issue and can give some counsel?? Thanks