I have installed MySQL server enterprise 5.1 on my local machine and now I want to install phpMyAdmin, but it does not work.
I have unrared phpMyAdmin to my server r
Had this problem a number of times on our setup, so I've made a check list.
This assumes you want phpMyAdmin connecting locally to MySQL using a UNIX socket rather than TCP/IP.
UNIX sockets should be slightly faster as they have less overhead and can be more secure as they can only be accessed locally.
Service
service mysqld statusservice mysqld startservice mysqld restartMySQL Config (my.cnf)
protocol=tcpPHP Config (php.ini)
If you can connect locally from the command line, but not from phpMyAdmin, and the socket file is not in the default location:
mysqli.default_socket = *location*pdo_myql.default_socket and mysql.default_socket just to be sureservice httpd restartphpMyAdmin Config (config.inc.php)
$cfg['Servers'][$i]['host'] = 'localhost';$cfg['Servers'][$i]['socket'] = '*location*';N.B.
As pointed out by @chk; Setting the $cfg['Servers'][$i]['host'] from localhost to 127.0.0.1 just causes the connection to use TCP/IP rather than using the socket and is more of a workaround than a solution.
The MySQL config setting bind-address= also only affects TCP/IP connections.
If you don't need remote connections, it is recommended to turn off TCP/IP listening with skip-networking.