If you are a web developer or administrator, aside from administering your web server, you should also be administering your MySQL database in terms of security. This database is open source and is commonly used with the PHP web server scripting language; tons of useful applications are being developed with this kind of setup. This is good, but it opens up issues, which we'll discuss here along with their solutions.
If you have configured your MySQL server to connect to the Internet, make sure it is behind a firewall to prevent remote attacks. If you are not protected, an attacker can initiate many attacks, including denial of service (DoS) attacks. If your server does not have proper authentication routines configured, they can even penetrate and compromise your server.
MySQL commonly uses port 3306. If you are running an Apache home-based server with MySQL in it, this port number might be exposed to the Internet. So make sure you have checked to see if this port is open, and that you only allow connections from trusted hosts. If not, you should close this port in a firewall, and open it only when it is highly necessary.
You can use this tool to scan your MySQL server for open ports.
Brute force attacks to your MySQL server
MySQL commonly asks for authentication if someone needs to log in to the server and access sensitive data. However, if you are using phpMyadmin to connect to the database, this is susceptible to brute force attacks.
To prevent brute force attacks, especially in a web -based interface using phpmyadmin, you need to add the patch mentioned in this update.
If you do not have full control of the phpmyadmin, which may be true in limited hosting accounts, then you cannot add that patch. Your only option is to contact your web host and ask if they have provided a layer of security to prevent brute force attacks, especially with the MySQL server. If they haven't, you can either ask them to upgrade, or switch to another hosting provider if you are really in need of brute force prevention.
The best way to provide brute force protection without changing phpMyadmin scripts or switching web hosts is by adding extremely strong passwords. In this case, any brute force attempts can take years before they succeed, if ever -- and most attackers will give up in that time.
Try to monitor your logs. If there is a series of failed login attempts, it is a sign that someone is planning to brute force the account. And then you can easily ban the IP using .htaccess or other methods.