Search for bind-address in file if it is localhost or 127.0.0.1 than you should be able to login but if it is something other than localhost than you have to give host to your mysql command mysql -uroot -h xxx.xxx.xxx.xxx -p Hope this helps somehow ..