Tag-Archive for » mysql «

Wednesday, October 22nd, 2008 | Author: Angelo

phpMyAdmin – Error

#2002 – The server is not responding (or the local MySQL server’s socket is not correctly configured)

Here is what worked for me on cPanel server.

root@server [~]# vi /usr/local/cpanel/base/3rdparty/phpMyAdmin/config.inc.php

find
$cfg['Servers'][$i]['socket'] = '';
change to
$cfg['Servers'][$i]['socket'] = '/var/lib/mysql/mysql.sock';

next line
$cfg['Servers'][$i]['connect_type'] = 'tcp';
change to
$cfg['Servers'][$i]['connect_type'] = 'socket';

now restart mysql service

root@server [~]# /etc/init.d/mysql restart

Thursday, October 02nd, 2008 | Author: Angelo

Hello,

Below are the tricks to secure mysql service on your cpanel server.

A. Change MySQL Default port :: Suppose if you want to configure mysql on port 5123 then edit my.cnf and configure 5123 as given below

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
port=5123

B. Restrict access to MySQL service for specific ips :: Add remote server ip in cPanel >> Mysql >> Access host

C. Encrypt the information transferred between them :: Configure secured port for mysql you can configure it as 5124 in the file stunnel.conf but make sure this file should be exist on both servers (your server and remote server to which you wish to give access).