I am using fresh installed Ubuntu 19.10 and trying to install LAMP, so I ran the following:
sudo apt-get install lamp-server^
After that, I had to configure mysql by running the command:
sudo mysql_secure_installation
Only to get the following message:
Securing the MySQL server deployment.
Enter password for user root:
Error: Access denied for user 'root'@'localhost' (using password: NO)
I've tried several solutions from Stack Overflow and other websites, but none worked for me.
Tried creating a .sql file setting a password to use it with --init-file and also tried skip-grant-tables as suggested here: Initial authorization issue in mysql. No results.
Furthermore, there is no /var/log/mysqld.log only /var/log/mysql/error.log so I also tried what JGlass suggested here: Setting root password in fresh mysql 5.7 installation. No results also.