Hi :
We did setup up remote mysql , then add both Server IP - Main server & Mysql Server - to firewall whitelist . you need know we use CSF Firewall plugin.
But when CSF enabled Query slowed and not good communication between 2 server . but when disable CSF this problem resolved and Query run quickly .
Is it any misconfig ? How can resolve this issue , we need CSF .
Thank You
Remote MySQL
Re: Remote MySQL
I'm not sure if this will help but i just picked it up on googling
CSF to configure remote MYSql
Add the following line in your /etc/csf/csf.allow on both the servers,
vi /etc/my.cnfport = 3306
bind-address=YOUR-SERVER-IP
# skip-networking -- Hash this entry
/etc/init.d/mysql restart
Grant access to remote IP address
Login to MySQL
mysql -u root –p mysql
If the remote Ip is 123.12.12.21
then use the below command
GRANT ALL ON db.* TO dbuser@'123.12.12.21' IDENTIFIED BY 'PASSWORD';
Then, allow access using the below command,
tcp|in|d=3306|s=192.168.x.x
tcp|out|d=3306|d=192.168.x.x
Restart csf with : csf -r
CSF to configure remote MYSql
Add the following line in your /etc/csf/csf.allow on both the servers,
vi /etc/my.cnfport = 3306
bind-address=YOUR-SERVER-IP
# skip-networking -- Hash this entry
/etc/init.d/mysql restart
Grant access to remote IP address
Login to MySQL
mysql -u root –p mysql
If the remote Ip is 123.12.12.21
then use the below command
GRANT ALL ON db.* TO dbuser@'123.12.12.21' IDENTIFIED BY 'PASSWORD';
Then, allow access using the below command,
tcp|in|d=3306|s=192.168.x.x
tcp|out|d=3306|d=192.168.x.x
Restart csf with : csf -r