Posted by Mike on 01/01/07 21:37
I'm unable to connect to my MySQL database with phpmyadmin when:
$cfg['Servers'][$i]['host'] = 'localhost';
However, I am able to connect when I change that information to
(NewMachine1 is the hostname of the computer):
$cfg['Servers'][$i]['host'] = 'NewMachine1';
Why am I not able to connect to MySQL via localhost, but I am able to
connect when I use the actual machine name. I have tested, and I made
sure I am able to ping localhost (resolves to 127.0.0.1), and I
verified my entry in /etc/hosts:
127.0.0.1 localhost.localdomain localhost
192.168.1.5 NewMachine1.domain.dom NewMachine1
MySQL is listening on port 3306 on 0.0.0.0 (which I believe means any
IP address on the machine).
Is there something I should look for, I don't know why I'm not able to
use localhost as opposed to the actual computer name?
[Back to original message]
|