i'm struggling with a shiny new ubuntu server. My MySQL root password is not working and I cannot change it. What I've tried:
sudo service mysql stop
sudo mysqld_safe --skip-grant-tables &
mysql
use mysql;
UPDATE mysql.user SET authentication_string=PASSWORD('MYPASS') WHERE User='root';
FLUSH PRIVILEGES;
quit
sudo service mysql start
mysql -u root -p
Enter password:
Access denied for user 'root'@'localhost'
I've also tried with mysql_secure_installation but the same as before
Some additional info
➜ ~ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04.2 LTS"
mysql Ver 14.14
Even tried removing mysql-server and re installing