Information Systems



MYSQL privileges

Some miscellaneous privilege commands. These are useful for diagnosing privilege problems on mysql.

mysql> grant all privileges on *.* to 'user'@'192.168.1.123';

mysql> flush privileges;

You can use wildcards. For instance the 192.168.1 subnet.
mysql> grant all privileges on *.* to 'user'@'192.168.1.%';

remember that when you create a new privilege entry, you also need to set a password for it.

SET PASSWORD FOR 'bob'@'%.loc.gov' = PASSWORD('newpass');

select host,user,password from mysql.user;

[http://dev.mysql.com/doc/refman/5.0/en/set-password.html]