December 10, 2004

Configure MySQL privilege for remote access

GRANT ALL PRIVILEGES ON *.* TO YourUserName@YourPublicIP IDENTIFIED BY "YourPassword";

YourUserName is the username that you would like to create.
YourPublicIP is the public IP address of your PC (can be IP range or use % to allow any host).
("211.72.20.%" =, quote IP range if with %)
YourPassword - You can setup a password for your account.

Don't forget flush privileges;

mysql> grant all privileges on *.* to pank@"211.72.20.%" identified by "1111";
Query OK, 0 rows affected (0.01 sec)

mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)

Posted by pank at December 10, 2004 04:24 PM
Post a comment

Remember personal info?