I am trying to setup LAMP on my OS, so I have installed apache
, php
, mysql
using the following commands:
sudo apt-get install apache2
sudo apt-get install php5
sudo apt-get install libapache2-mod-php5
sudo apt-get install mysql-server libapache2-mod-auth-mysql php5-mysql
sudo apt-get install phpmyadmin
Everything works fine except that I cannot log into MySQL (which leads to phpmyadmin
failure login). I'm getting the errors:
#1045 Cannot log in to the MySQL server
Access denied for user 'root'@'localhost' (using password: YES)
I googled the problem and I have also tried to reinstall all installed components, but the same result came up!
On Windows, I usually modified the content of mysql
configuration file, but in Ubuntu nothing is the same as Windows!