Issue :

How to prevent anybody from accessing MySQL databases hosted on the server from any local PC ?

Solution :

This can be achieved in two ways :

1. By blocking the port 3306 . You can use iptables in order to do this :

/sbin/iptables -A INPUT -i eth0 -p tcp –destination-port 3306 -j DROP


2. Put the following in my.cnf :


Source : WHT

Contact Us On WhatsApp