MySQL: unistall MySQL from Ubuntu and reinstall it

Remove mysql-server completely

sudo apt-get remove --purge mysql*
sudo apt-get purge mysql*
sudo apt-get autoremove
sudo apt-get autoclean
sudo apt-get remove dbconfig-mysql

Install mysql server

sudo apt-get dist-upgrade
sudo apt-get install mysql-server